home *** CD-ROM | disk | FTP | other *** search
/ Internet Info 1994 March / Internet Info CD-ROM (Walnut Creek) (March 1994).iso / networking / fax / leffler / v2.1.0.patch-2 < prev    next >
Encoding:
Text File  |  1993-06-25  |  95.7 KB  |  2,811 lines

  1. #! /bin/sh
  2. # patch script for converting a5 to a008
  3. TOP=.
  4.  
  5. Patch()
  6. {
  7.     echo "Patch $1:"; patch -s $TOP/$1
  8. }
  9.  
  10. NewFile()
  11. {
  12.     echo "New file $1"; cat >$TOP/$1
  13. }
  14.  
  15. NewDir()
  16. {
  17.     echo "New directory $1"; mkdir $TOP/$1
  18. }
  19.  
  20. RmFile()
  21. {
  22.     echo "Remove $1"; rm -f $TOP/$1.orig; mv $TOP/$1 $TOP/$1.orig
  23. }
  24.  
  25. Patch BLURB<<'EOF-EOF-EOF'
  26. 348,349c348,349
  27. < FlexFAX Mailing List
  28. < --------------------
  29. ---
  30. > FlexFAX Mail List
  31. > -----------------
  32. 354c354,358
  33. <     flexfax-request@sgi.com
  34. ---
  35. >     majordomo@whizzer.wpd.sgi.com
  36. > For example, to subscribe, send the line "subscribe flexfax" in
  37. > the body of your message.  The line "help" will return a list of
  38. > the commands understood by the mailing list management software.
  39. EOF-EOF-EOF
  40. Patch HOWTO<<'EOF-EOF-EOF'
  41. 1c1
  42. < $Header: /usr/people/sam/fax/RCS/HOWTO,v 1.13 93/04/18 18:06:45 sam Exp $
  43. ---
  44. > $Header: /usr/people/sam/fax/RCS/HOWTO,v 1.14 93/05/24 11:42:16 sam Exp $
  45. 105c105,109
  46. <     flexfax-request@sgi.com
  47. ---
  48. >     majordomo@whizzer.wpd.sgi.com
  49. > For example, to subscribe, send the line "subscribe flexfax" in
  50. > the body of your message.  The line "help" will return a list of
  51. > the commands understood by the mailing list management software.
  52. EOF-EOF-EOF
  53. Patch README<<'EOF-EOF-EOF'
  54. 1c1
  55. < $Header: /usr/people/sam/fax/RCS/README,v 1.48 93/05/17 16:13:01 sam Exp $
  56. ---
  57. > $Header: /usr/people/sam/fax/RCS/README,v 1.50 93/06/25 14:56:34 sam Exp $
  58. 69a70
  59. >     USR Sportster        (firmware revision XXX or newer)
  60. 86c87
  61. <     Abaton InterFax 24/96
  62. ---
  63. >     Abaton InterFax 24/96    NOTE: THE ABATON DRIVER IS CURRENTLY BUSTED
  64. 306,307c307,308
  65. < Directory for library files    /usr/local/lib/fax
  66. < Directory for sendfax filters:    /usr/local/lib/fax
  67. ---
  68. > Directory for lib data files    /usr/local/lib/fax
  69. > Directory for lib executables:    /usr/local/lib/fax
  70. 466,467c467,468
  71. <   software flow control (and all the Class 1 modems tried so far do
  72. <   not support hardware flow control)
  73. ---
  74. >   software flow control (and most of the Class 1 modems tried so far
  75. >   do not support hardware flow control)
  76. 480c481,482
  77. < (something that does not work well with many fax modems).
  78. ---
  79. > (something that does not work well with many fax modems)--most folks
  80. > use /dev/cu* for communicating with modems.
  81. 612c614,616
  82. < placing a call--e.g AT+FCLASS=0DT<phone number>.
  83. ---
  84. > placing a call--e.g AT+FCLASS=0DT<phone number>.  Alternatively, you
  85. > can fiddle with the configuration parameters and keep the modem setup
  86. > for data use when the server is not actively using the modem.
  87. 682,698c686,705
  88. < Incoming facsimile are placed in the recvq subdirectory of the
  89. < spooling area and probably will need to be cleaned up periodically.
  90. < Likewise there is logging information in the log subdirectory and
  91. < accounting information in the etc subdirectory of the spooling area
  92. < that may need some attention (scripts similar to those used for
  93. < maintaining sendmail and uucp logs and queues should probably be run
  94. < out of cron).  If you want to do accounting check out the simple-minded
  95. < awk scripts util/xfer.awk util/xferdest.awk for a basic attack on how
  96. < to process the etc/xferlog accounting file maintained for facsimile
  97. < transmissions and receptions.  Otherwise the only matter to be
  98. < concerned with is the support for data connections.  If your modems are
  99. < capable of differentiating data connections from facsimile connections
  100. < the fax server can invoke a getty process and permit incoming data
  101. < connections.  Beware that if you enable this facility you should take the
  102. < normal precautions you would take when there are dialup ports on your
  103. < machine.  Specifically, make sure that you have passwords, appropriate
  104. < file protections, and proper configuration of uucp or similar.
  105. ---
  106. > Incoming facsimile are placed in the recvq subdirectory of the spooling
  107. > area and probably will need to be cleaned up periodically.  Likewise
  108. > there is logging information in the log subdirectory and accounting
  109. > information in the etc subdirectory of the spooling area that may need
  110. > some attention (scripts similar to those used for maintaining sendmail
  111. > and uucp logs and queues should probably be run out of cron).  If you
  112. > want to do accounting check out the simple-minded awk scripts
  113. > util/xfer.awk util/xferdest.awk for a basic attack on how to process
  114. > the etc/xferlog accounting file maintained for facsimile transmissions
  115. > and receptions.  Otherwise the only matter to be concerned with is the
  116. > support for data connections.  If your modems are capable of
  117. > differentiating data connections from facsimile connections the fax
  118. > server can invoke a getty process and permit incoming data
  119. > connections.  Alternatively, if your modem does not support an adaptive
  120. > answer facility, but it is a Class 1 modem, the server may be able to
  121. > do adaptive answering in software.  In any event, beware that if you
  122. > enable data connections you should take the normal precautions you
  123. > would take when there are dialup ports on your machine.  Specifically,
  124. > make sure that you have passwords, appropriate file protections, and
  125. > proper configuration of uucp or similar.
  126. 699a707,718
  127. > If you encounter problems with sending or receiving facsimile you can
  128. > enable copious tracing information by editing the configuration
  129. > file(s).  Consult the section on Troubleshooting and the config(4F) and
  130. > log(4F) manual pages.
  131. > Adaptive-answering Strategies
  132. > -----------------------------
  133. > If your modem supports a good adaptive answering facility, then it
  134. > should be enabled with the ModemSetupAACmd and the server system will
  135. > automatically service fax or data calls as appropriate.
  136. 702,708c721,725
  137. < facsimile is supported without problems.  If you want to always process
  138. < incoming calls fax connections, then you do not need to do anything;
  139. < this is the normal setup.  If you want to always process incoming calls
  140. < as data connections, then you should setup your modem configuration so
  141. < that the ModemAnswerCmd parameter in the configuration file causes the
  142. < phone to be answered strictly as a data modem.  For example, if you
  143. < have a Class 2 modem, the following should do this:
  144. ---
  145. > facsimile is supported without problems.  If you have a Class 1 modem,
  146. > then you can request that the server employ a simple adaptive answering
  147. > strategy whereby incoming calls are first answered as if they are for a
  148. > fax machine and, if that fails, then answered as if they are for a data
  149. > modem.  This facility is enabled by specifying something like:
  150. 710c727,730
  151. <     ModemAnswerCmd:    +FCLASS=0A
  152. ---
  153. >     AdaptiveAnswer:    yes        # enable adaptive answer
  154. >     ModemAnswerCmd:    +FCLASS=1;A    # default is to answer as fax
  155. >     ModemAnswerDataCmd:    H+FCLASS=0;A    # hangup and answer as data
  156. >     Class1RecvIdentTimer: 10000        # timeout fax answer in 10 secs
  157. 711a732,784
  158. > in the configuration file.   The above lines cause the fax server to do
  159. > the following in response to an incoming phone call:
  160. >     1. Issue "AT+FCLASS=1;A" to answer the phone call in Class 1;
  161. >        i.e. as a fax machine (issuing CNG tones).
  162. >     2. Send TSI and DIS frames as required by the fax protocol.
  163. >     3. Wait for DCS from the caller (if it is a fax machine).
  164. >     4. Timeout waiting for DCS in 10 seconds (or whatever is specified
  165. >        for Class1RecvIdentTimer).
  166. >     5. Issue "ATH+FCLASS=0;A" to hangup and then re-answer the phone
  167. >        in Class 0; i.e. as a data modem.
  168. > This technique assumes many things about the capabilities of the modem
  169. > and the local telephony service and may not work for all Class 1 modems
  170. > or for all locales.
  171. > A second facility supported by the fax server in lieu of adaptive
  172. > answering is a ``rotary of answering techniques''.  The general idea is
  173. > that a list of alternative ways to answer the phone is supplied and the
  174. > server will rotate through the list until it finds one that works.  For
  175. > example, one might specify something like:
  176. >     AnswerRotary: "fax data"
  177. > which would instruct the server to answer incoming calls as if they
  178. > were from a fax machine until a call was received from something other
  179. > than a fax machine, in which case it would then answer subsequent calls
  180. > as a data modem until a non-data call was received (in which case it
  181. > would go back to fax).  The rotary list can have up to three items,
  182. > with items being selected from one of: fax, data, voice, and any
  183. > (answer a call of an unknown type).  The voice answering request is
  184. > reserved for future development.  Finally, in conjunction with the
  185. > rotary answer facility there is an AnswerBias parameter that can be
  186. > used to specify an index into the rotary list to use after
  187. > *successfull* calls.  In the above example, this parameter can be used,
  188. > to force calls to always be answered first as data by specifying:
  189. >     AnswerRotary: "fax data"
  190. >     AnswerBias:      1
  191. > Non-adaptive-answering Strategies
  192. > ---------------------------------
  193. > If you want to always process incoming calls as fax connections, then
  194. > you do not need to do anything; this is the normal setup.  If you want
  195. > to always process incoming calls as data connections, then you should
  196. > setup your modem configuration so that the ModemAnswerCmd parameter in
  197. > the configuration file causes the phone to be answered strictly as a
  198. > data modem.  For example, if you have a Class 1 or Class 2 modem, the
  199. > following should do this:
  200. >     ModemAnswerCmd:    +FCLASS=0;A
  201. 720,725c793,796
  202. < server pick up the phone.  Note that with a little judicious config
  203. < file hacking, you can arrange to have the server answer the phone
  204. < either as a data modem or as a fax modem.  Future versions of the
  205. < system will provide better support for this (i.e. not require that you
  206. < edit the configuration file before telling the server to answer the
  207. < phone).
  208. ---
  209. > server pick up the phone.  Note that by using the -h option to faxanswer
  210. > you can control whether the fax server answers a phone call as fax,
  211. > or data (answering as voice is also supported for compatibility with
  212. > future work).
  213. 727,730d797
  214. < If you encounter problems with sending or receiving facsimile you can
  215. < enable copious tracing information by editing the configuration
  216. < file(s).  Consult the next section and the config(4F) and log(4F)
  217. < manual pages.
  218. 732d798
  219. 799,803c865,869
  220. < Andrew Ford    Wolfgang Henke    Bert Hooyman    Masao Kitano
  221. < Carsten Koch    Rickard Linck    Kevin McManamon    Bill Morrow
  222. < Jonas Olsson    Dave Packer    Damon Permezel    David Pike
  223. < Amir Plivatsky    Andy Rabagliati    Eric Rescorla    Daniel Rosenblatt
  224. < Tim Rylance    Brent Townshend    
  225. ---
  226. > Andrew Ford    Wolfgang Henke    Bert Hooyman    Brian Katzung
  227. > Masao Kitano    Carsten Koch    Rickard Linck    Kevin McManamon
  228. > Bill Morrow    Jonas Olsson    Dave Packer    Damon Permezel
  229. > David Pike    Amir Plivatsky    Andy Rabagliati    Eric Rescorla
  230. > Daniel Rosenblatt Tim Rylance    Brent Townshend    
  231. 821c887
  232. < such as getting your name removed from it, send a request to
  233. ---
  234. > such as getting your name removed from it, send your request to
  235. 823c889
  236. <     flexfax-request@sgi.com
  237. ---
  238. >     majordomo@whizzer.wpd.sgi.com
  239. 825,828c891,893
  240. < If you are a first-time user of this software you can join the mailing
  241. < list by filling out the survey form in the file SURVEY and post it to
  242. < the above email address (the form is setup as an MH form file to
  243. < simplify this procedure).
  244. ---
  245. > For example, to subscribe, send the line "subscribe flexfax" in
  246. > the body of your message.  The line "help" will return a list of
  247. > the commands understood by the mailing list management software.
  248. 829a895,898
  249. > If you have not previously done so, please fill out the survey form in
  250. > the file SURVEY and post it to flexfax-survey@whizzer.wpd.sgi.com (the
  251. > form is setup as an MH form file to simplify this procedure).
  252. 874,876d942
  253. < $Header: /usr/people/sam/fax/RCS/README,v 1.48 93/05/17 16:13:01 sam Exp $
  254. 896a963,965
  255. > The file 3.2.patch in the above ftp directories is a shell
  256. > script that should be applied to the 3.2beta source code.
  257. 899a969,988
  258. > TIFF Mailing List
  259. > -----------------
  260. > A mailing list for users of this software is located on sgi.com.
  261. > If you want to join this mailing list or have a list-related request
  262. > such as getting your name removed from it, send a request to
  263. >     majordomo@whizzer.wpd.sgi.com
  264. > For example, to subscribe, send the line "subscribe tiff" in
  265. > the body of your message.  The line "help" will return a list of
  266. > the commands understood by the mailing list management software.
  267. > Submissions (including bug reports) should be directed to:
  268. >     tiff@sgi.com
  269. > When corresponding about this software please always specify what
  270. > version you have, what system you're running on.
  271. EOF-EOF-EOF
  272. Patch SURVEY<<'EOF-EOF-EOF'
  273. 1c1
  274. < To: flexfax-request@sgi.com (FlexFAX Mailing List Administrator)
  275. ---
  276. > To: flexfax-survey@whizzer.wpd.sgi.com (FlexFAX Survey-or)
  277. EOF-EOF-EOF
  278. Patch configure<<'EOF-EOF-EOF'
  279. 2c2
  280. < #    $Header: /usr/people/sam/fax/RCS/configure,v 1.68 93/05/17 15:37:55 sam Exp $
  281. ---
  282. > #    $Header: /usr/people/sam/fax/RCS/configure,v 1.69 93/06/18 11:43:28 sam Exp $
  283. 582,583c582,583
  284. <     getParameter LIB $1;             FAX_LIBDIR="$param"
  285. <                         FAX_FILTERDIR="$param"
  286. ---
  287. >     getParameter LIBDATA $1;             FAX_LIBDATA="$param"
  288. >     getParameter LIBEXEC $1;             FAX_LIBEXEC="$param"
  289. 603,604c603,605
  290. <     protoFAX_LIBDIR="$FAX_LIBDIR"
  291. <     protoFAX_FILTERDIR="$FAX_FILTERDIR"
  292. ---
  293. >     protoFAX_LIBDATA="$FAX_LIBDATA"
  294. >     protoFAX_LIBEXEC="$FAX_LIBEXEC"
  295. >     protoFAX_LIBFILTER="$FAX_LIBFILTER"
  296. 627,628c628,629
  297. < Directory for library files    $FAX_LIBDIR
  298. < Directory for sendfax filters:    $FAX_FILTERDIR
  299. ---
  300. > Directory for lib data files:    $FAX_LIBDATA
  301. > Directory for lib executables:    $FAX_LIBEXEC
  302. 696,700c697,700
  303. <     promptForNonNullStringParameter "$FAX_LIBDIR" \
  304. <         "Directory to install library files";    FAX_LIBDIR="$param"
  305. <     promptForNonNullStringParameter "$FAX_FILTERDIR" \
  306. <         "Directory to install sendfax filter programs";
  307. <                             FAX_FILTERDIR="$param"
  308. ---
  309. >     promptForNonNullStringParameter "$FAX_LIBDATA" \
  310. >         "Directory to install library data files";    FAX_LIBDATA="$param"
  311. >     promptForNonNullStringParameter "$FAX_LIBEXEC" \
  312. >         "Directory to install library executables";    FAX_LIBEXEC="$param"
  313. 756c756,757
  314. <      -o "$FAX_LIBDIR"    != "$protoFAX_LIBDIR"    \
  315. ---
  316. >      -o "$FAX_LIBDATA"    != "$protoFAX_LIBDATA"    \
  317. >      -o "$FAX_LIBEXEC"    != "$protoFAX_LIBEXEC"    \
  318. 772c773,774
  319. <         "/^LIB[     ]*=/s;=[^#]*;=${FAX_LIBDIR};" \
  320. ---
  321. >         "/^LIBDATA[     ]*=/s;=[^#]*;=${FAX_LIBDATA};" \
  322. >         "/^LIBEXEC[     ]*=/s;=[^#]*;=${FAX_LIBEXEC};" \
  323. 794d795
  324. < getHParameter FAX_LIBDIR $f;    protoFAX_LIBDIR="$param"
  325. 796c797,798
  326. < getHParameter FAX_FILTERDIR $f;    protoFAX_FILTERDIR="$param"
  327. ---
  328. > getHParameter FAX_LIBDATA $f;    protoFAX_LIBDATA="$param"
  329. > getHParameter FAX_LIBEXEC $f;    protoFAX_LIBEXEC="$param"
  330. 799c801,802
  331. < if [    "$FAX_LIBDIR"    != "$protoFAX_LIBDIR"    \
  332. ---
  333. > if [    "$FAX_LIBDATA"    != "$protoFAX_LIBDATA"    \
  334. >      -o "$FAX_LIBEXEC"    != "$protoFAX_LIBEXEC"    \
  335. 801d803
  336. <      -o "$FAX_FILTERDIR" != "$protoFAX_FILTERDIR" \
  337. 809c811,812
  338. <         "/FAX_LIBDIR/s;${protoFAX_LIBDIR};${FAX_LIBDIR};" \
  339. ---
  340. >         "/FAX_LIBDATA/s;${protoFAX_LIBDATA};${FAX_LIBDATA};" \
  341. >         "/FAX_LIBEXEC/s;${protoFAX_LIBEXEC};${FAX_LIBEXEC};" \
  342. EOF-EOF-EOF
  343. Patch distrules<<'EOF-EOF-EOF'
  344. 1c1
  345. < #    $Header: /usr/people/sam/fax/RCS/distrules,v 1.55 93/05/20 15:53:43 sam Exp $
  346. ---
  347. > #    $Header: /usr/people/sam/fax/RCS/distrules,v 1.57 93/06/24 13:48:13 sam Exp $
  348. 200a201
  349. >     etc/probemodem.sh            \
  350. 306d306
  351. <     faxd/FaxRecvdData.c++            \
  352. 309d308
  353. <     faxd/FaxRequestData.c++            \
  354. EOF-EOF-EOF
  355. Patch dist/flexfax.alpha<<'EOF-EOF-EOF'
  356. 1c1
  357. < define ALPHA 5
  358. ---
  359. > define ALPHA 008
  360. EOF-EOF-EOF
  361. Patch dist/newalpha<<'EOF-EOF-EOF'
  362. 2c2
  363. < #    $Header: /usr/people/sam/fax/dist/RCS/newalpha,v 1.2 93/04/18 18:05:01 sam Exp $
  364. ---
  365. > #    $Header: /usr/people/sam/fax/dist/RCS/newalpha,v 1.3 93/05/21 12:13:46 sam Exp $
  366. 29,30c29,30
  367. <     ALPHA=`cat flexfax.alpha|sed -e 's/define.ALPHA.//'`
  368. <     ALPHA=`expr $ALPHA + 1`
  369. ---
  370. >     ALPHA=`cat flexfax.alpha`; rm -f flexfax.alpha
  371. >     echo "$ALPHA" | awk '{ printf "define ALPHA %03d\n", $3+1}' > flexfax.alpha
  372. 32c32
  373. <     ALPHA=1
  374. ---
  375. >     echo "define ALPHA 001" >flexfax.alpha
  376. 34,35d33
  377. < rm -f flexfax.alpha
  378. < echo "define ALPHA ${ALPHA}" >flexfax.alpha
  379. EOF-EOF-EOF
  380. Patch etc/config.att-dataport<<'EOF-EOF-EOF'
  381. 1c1
  382. < # $Header: /usr/people/sam/fax/etc/RCS/config.att-dataport,v 1.2 93/05/17 16:27:09 sam Exp $
  383. ---
  384. > # $Header: /usr/people/sam/fax/etc/RCS/config.att-dataport,v 1.3 93/05/26 11:16:05 sam Exp $
  385. 7a8,9
  386. > #
  387. > # CONFIG: CLASS1: 144: Manufacturer='AT&T' Model=Dataport
  388. EOF-EOF-EOF
  389. Patch etc/config.dsi-scout+<<'EOF-EOF-EOF'
  390. 1c1
  391. < # $Header: /usr/people/sam/fax/etc/RCS/config.dsi-scout+,v 1.9 93/05/06 12:51:11 sam Exp $
  392. ---
  393. > # $Header: /usr/people/sam/fax/etc/RCS/config.dsi-scout+,v 1.10 93/05/26 11:16:50 sam Exp $
  394. 8a9,10
  395. > #
  396. > # CONFIG: CLASS1: 961: Manufacturer=Digicom Model=Scout+
  397. EOF-EOF-EOF
  398. Patch etc/config.everex-2496d<<'EOF-EOF-EOF'
  399. 1c1
  400. < # $Header: /usr/people/sam/fax/etc/RCS/config.everex-2496d,v 1.10 93/05/06 12:51:11 sam Exp $
  401. ---
  402. > # $Header: /usr/people/sam/fax/etc/RCS/config.everex-2496d,v 1.11 93/05/26 11:16:51 sam Exp $
  403. 7a8,9
  404. > #
  405. > # CONFIG: CLASS2: Everex*
  406. EOF-EOF-EOF
  407. Patch etc/config.mt-1432<<'EOF-EOF-EOF'
  408. 1c1
  409. < # $Header: /usr/people/sam/fax/etc/RCS/config.mt-1432,v 1.3 93/05/06 12:51:12 sam Exp $
  410. ---
  411. > # $Header: /usr/people/sam/fax/etc/RCS/config.mt-1432,v 1.4 93/05/26 11:16:51 sam Exp $
  412. 3a4,5
  413. > #
  414. > # CONFIG: CLASS2: Multi-Tech*
  415. EOF-EOF-EOF
  416. Patch etc/config.nuvo-voyager<<'EOF-EOF-EOF'
  417. 1c1
  418. < # $Header: /usr/people/sam/fax/etc/RCS/config.nuvo-voyager,v 1.5 93/05/06 12:51:13 sam Exp $
  419. ---
  420. > # $Header: /usr/people/sam/fax/etc/RCS/config.nuvo-voyager,v 1.6 93/05/26 11:16:52 sam Exp $
  421. 6a7,8
  422. > #
  423. > # CONFIG: CLASS1: 242: Manufacturer=Nuvo Model="Voyager 9642PFX"
  424. EOF-EOF-EOF
  425. Patch etc/config.rockwell<<'EOF-EOF-EOF'
  426. 1c1
  427. < # $Header: /usr/people/sam/fax/etc/RCS/config.rockwell,v 1.12 93/05/06 12:51:13 sam Exp $
  428. ---
  429. > # $Header: /usr/people/sam/fax/etc/RCS/config.rockwell,v 1.13 93/05/26 11:16:53 sam Exp $
  430. 16a17,18
  431. > #
  432. > # CONFIG: CLASS2: ROCKWELL*
  433. EOF-EOF-EOF
  434. Patch etc/config.rockwell-class1<<'EOF-EOF-EOF'
  435. 1c1
  436. < # $Header: /usr/people/sam/fax/etc/RCS/config.rockwell-class1,v 1.13 93/05/06 12:51:14 sam Exp $
  437. ---
  438. > # $Header: /usr/people/sam/fax/etc/RCS/config.rockwell-class1,v 1.14 93/05/26 11:16:54 sam Exp $
  439. 9a10,12
  440. > #
  441. > # CONFIG: CLASS1: 999: Manufacturer=ROCKWELL Model=RC144AC
  442. > # CONFIG: CLASS1: 998: Manufacturer=ROCKWELL Model=RC96AC
  443. EOF-EOF-EOF
  444. Patch etc/config.telebit-wb<<'EOF-EOF-EOF'
  445. 1c1
  446. < # $Header: /usr/people/sam/fax/etc/RCS/config.telebit-wb,v 1.4 93/05/06 12:51:15 sam Exp $
  447. ---
  448. > # $Header: /usr/people/sam/fax/etc/RCS/config.telebit-wb,v 1.5 93/05/26 11:16:55 sam Exp $
  449. 5a6,7
  450. > #
  451. > # CONFIG: CLASS2: Telebit*
  452. EOF-EOF-EOF
  453. Patch etc/config.usr-courier<<'EOF-EOF-EOF'
  454. 1c1
  455. < # $Header: /usr/people/sam/fax/etc/RCS/config.usr-courier,v 1.4 93/05/11 14:23:10 sam Exp $
  456. ---
  457. > # $Header: /usr/people/sam/fax/etc/RCS/config.usr-courier,v 1.5 93/05/26 11:16:56 sam Exp $
  458. 7a8,9
  459. > #
  460. > # CONFIG: CLASS1: 1444: Manufacturer=USRobotics Model=Courier
  461. EOF-EOF-EOF
  462. Patch etc/config.zyxel-1496e<<'EOF-EOF-EOF'
  463. 1c1
  464. < # $Header: /usr/people/sam/fax/etc/RCS/config.zyxel-1496e,v 1.12 93/05/11 16:50:13 sam Exp $
  465. ---
  466. > # $Header: /usr/people/sam/fax/etc/RCS/config.zyxel-1496e,v 1.13 93/05/26 11:16:57 sam Exp $
  467. 12a13,14
  468. > #
  469. > # CONFIG: CLASS2: ZyXEL*
  470. EOF-EOF-EOF
  471. Patch etc/faxaddmodem.sh<<'EOF-EOF-EOF'
  472. 2c2
  473. < #    $Header: /usr/people/sam/fax/etc/RCS/faxaddmodem.sh,v 1.53 93/05/11 14:20:42 sam Exp $
  474. ---
  475. > #    $Header: /usr/people/sam/fax/etc/RCS/faxaddmodem.sh,v 1.55 93/06/23 14:04:05 sam Exp $
  476. 92a93
  477. > MODEMCONFIG=$SPOOL/etc        # location of modem configuration files
  478. 397c398
  479. < x=`ypcat services 2>/dev/null | grep '^fax'`
  480. ---
  481. > x=`ypcat services 2>/dev/null | grep '^fax[     ]'`
  482. 399c400
  483. <     x=`grep '^fax' $SERVICES`
  484. ---
  485. >     x=`grep '^fax[     ]' $SERVICES`
  486. 929c930
  487. < ModemType="" Manufacturer="" Model=""
  488. ---
  489. > ModemType="" Manufacturer="" Model="" ProtoType="config.skel"
  490. 936c937
  491. <     ModemType="Class2"
  492. ---
  493. >     ModemType=Class2
  494. 938c939,947
  495. ---
  496. >     #
  497. >     # Use AT+FMDL? to get the model and AT+FMFR? to get
  498. >     # manuafacturer's identity and then compare them against
  499. >     # the set of known values in the Class 2 config files.
  500. >     # Note that we do this with a tricky bit of shell
  501. >     # hacking--generating a case statement that we
  502. >     # then eval with the result being the setup of the
  503. >     # ProtoType shell variable.
  504. >     #
  505. 945a955,962
  506. >     eval `(cd $MODEMCONFIG; \
  507. >         grep 'CONFIG:[     ]*CLASS2' config.* |\
  508. >         awk -F: '
  509. >         BEGIN { print "case \"$Manufacturer-$Model\" in" }
  510. >         { print $4 ") ProtoType=" $1 ";;" }
  511. >         END { print "*) ProtoType=config.class2;;"; print "esac" }
  512. >         ')`
  513. 948,949c965
  514. <     ModemType="Class1";
  515. <     Manufacturer=Unknown Model=Unknown
  516. ---
  517. >     ModemType=Class1 Manufacturer=Unknown Model=Unknown
  518. 952,953c968,973
  519. <     # Use ATI0 to get the product code--are these
  520. <     # really going to be unique?
  521. ---
  522. >     # Use ATI0 to get the product code and then compare
  523. >     # it against the set of known values in the config
  524. >     # files.  Note that we do this with a tricky bit of
  525. >     # shell hacking--generating a case statement that we
  526. >     # then eval with the result being the setup of the
  527. >     # Manufacturer, Model, and ProtoType shell variables.
  528. 956,961c976,984
  529. <     case "$RESPONSE" in
  530. <     144)    Manufacturer=ATT    Model=DataPort;;
  531. <     242)    Manufacturer=Nuvo    Model="Voyager 9642PFX";;
  532. <     961)    Manufacturer=Digicom    Model=Scout+;;
  533. <     1444)    Manufacturer=USRobotics    Model=Courier;;
  534. <     esac
  535. ---
  536. >     echo "Product code is \"$RESPONSE\"."
  537. >     eval `(cd $MODEMCONFIG; \
  538. >         grep 'CONFIG:[     ]*CLASS1' config.* |\
  539. >         awk -F: '
  540. >         BEGIN { print "case \"$RESPONSE\" in" }
  541. >         { print $4 ") " $5 " ProtoType=" $1 ";;" }
  542. >         END { print "*) ProtoType=config.class1;;"; print "esac" }
  543. >         ')`
  544. 968c991
  545. <     giveup;
  546. ---
  547. >     giveup
  548. 1001d1023
  549. < ProtoType="config.skel"
  550. 1003,1029c1025,1026
  551. < Class2)
  552. <     case $Manufacturer in
  553. <     ZyXEL*)
  554. <     echo "Using prototype ZyXEL configuration file..."
  555. <     ProtoType=config.zyxel-1496e
  556. <     ;;
  557. <     ROCKWELL*)
  558. <     echo "Using prototype Rockwell configuration file..."
  559. <     ProtoType=config.rockwell
  560. <     ;;
  561. <     Everex*)
  562. <     echo "Using prototype Everex 24/96D configuration file..."
  563. <     ProtoType=config.everex-2496d
  564. <     ;;
  565. <     Telebit*)
  566. <     echo "Using prototype Telebit WorldBlazer configuration file..."
  567. <     ProtoType=config.telebit-wb
  568. <     ;;
  569. <     Multi-Tech*)
  570. <     echo "Using prototype Multi-Tech $Model configuration file..."
  571. <     ProtoType=config.mt-1432
  572. <     ;;
  573. <     *)
  574. <     echo "Using prototype Class 2 configuration file..."
  575. <     ProtoType=config.class2
  576. <     ;;
  577. <     esac
  578. ---
  579. > Class1|Class2)
  580. >     echo "Using prototype configuration file $ProtoType..."
  581. 1031,1058d1027
  582. < Class1)
  583. <     case $Manufacturer-$Model in
  584. <     ROCKWELL*)
  585. <     echo "Using prototype Rockwell Class 1 configuration file..."
  586. <     ProtoType=config.rockwell-class1
  587. <     ;;
  588. <     Digicom*)
  589. <     echo "Using prototype Digicom configuration file..."
  590. <     ProtoType=config.dsi-scout+
  591. <     ;;
  592. <     Nuvo*)
  593. <     echo "Using prototype Nuvo configuration file..."
  594. <     ProtoType=config.nuvo-voyager
  595. <     ;;
  596. <     ATT-DataPort)
  597. <     echo "Using prototype AT&T DataPort configuration file..."
  598. <     ProtoType=config.att-dataport
  599. <     ;;
  600. <     USRobotics-Courier)
  601. <     echo "Using prototype US Robotics Courier configuration file..."
  602. <     ProtoType=config.usr-courier
  603. <     ;;
  604. <     *)
  605. <     echo "Using prototype Class 1 configuration file..."
  606. <     ProtoType=config.class1
  607. <     ;;
  608. <     esac
  609. <     ;;
  610. 1065c1034
  611. < proto=$SPOOL/etc/$ProtoType
  612. ---
  613. > proto=$MODEMCONFIG/$ProtoType
  614. 1080c1049
  615. <     proto=$SPOOL/etc/$ProtoType;
  616. ---
  617. >     proto=$MODEMCONFIG/$ProtoType;
  618. 1594c1563
  619. < eval sed $ServerCmds $ModemCmds $proto >$CONFIG
  620. ---
  621. > eval sed $ServerCmds $ModemCmds '-e /CONFIG:/d' $proto >$CONFIG
  622. EOF-EOF-EOF
  623. NewFile etc/probemodem.sh<<'EOF-EOF-EOF'
  624. #! /bin/sh
  625. #    $Header: /usr/people/sam/fax/etc/RCS/probemodem.sh,v 1.1 93/06/24 13:45:47 sam Exp $
  626. #
  627. # FlexFAX Facsimile Software
  628. #
  629. # Copyright (c) 1993 Sam Leffler
  630. # Copyright (c) 1993 Silicon Graphics, Inc.
  631. # Permission to use, copy, modify, distribute, and sell this software and 
  632. # its documentation for any purpose is hereby granted without fee, provided
  633. # that (i) the above copyright notices and this permission notice appear in
  634. # all copies of the software and related documentation, and (ii) the names of
  635. # Sam Leffler and Silicon Graphics may not be used in any advertising or
  636. # publicity relating to the software without the specific, prior written
  637. # permission of Sam Leffler and Silicon Graphics.
  638. # THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 
  639. # EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 
  640. # WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.  
  641. # IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR
  642. # ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND,
  643. # OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
  644. # WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 
  645. # LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 
  646. # OF THIS SOFTWARE.
  647. #
  648.  
  649. #
  650. # probemodem [tty]
  651. #
  652. # This script probes a modem attached to a serial line and
  653. # reports the results of certain commands.
  654. #
  655. PATH=/bin:/usr/bin:/etc
  656. test -d /usr/ucb  && PATH=$PATH:/usr/ucb        # Sun and others
  657. test -d /usr/bsd  && PATH=$PATH:/usr/bsd        # Silicon Graphics
  658. test -d /usr/5bin && PATH=/usr/5bin:$PATH:/usr/etc    # Sun and others
  659. test -d /usr/sbin && PATH=/usr/sbin:$PATH        # 4.4BSD-derived
  660.  
  661. if [ -d /etc/saf ]; then
  662.     # uname -s is unreliable on svr4 as it can return the nodename
  663.     OS=svr4
  664. else
  665.     OS=`uname -s 2>/dev/null || echo unknown`    # system identification
  666. fi
  667. SPEED=2400                    # rate for talking to modem
  668.  
  669. while [ x"$1" != x"" ] ; do
  670.     case $1 in
  671.     -os)    OS=$2; shift;;
  672.     -s)        SPEED=$2; shift;;
  673.     -*)        echo "Usage: $0 [-os OS] [-s SPEED] [ttyname]"; exit 1;;
  674.     *)        TTY=$1;;
  675.     esac
  676.     shift
  677. done
  678.  
  679. LOCKDIR=/usr/spool/locks    # UUCP locking directory
  680. OUT=/tmp/addmodem$$        # temp file in which modem output is recorded
  681. CAT="cat -u"            # something to do unbuffered reads and writes
  682.  
  683. #
  684. # Figure out which brand of echo we have and define
  685. # prompt and printf shell functions accordingly.
  686. # Note that we assume that if the System V-style
  687. # echo is not present, then the BSD printf program
  688. # is available.
  689. #
  690. if [ `echo foo\\\c`@ = "foo@" ]; then
  691.     # System V-style echo supports \r
  692.     # and \c which is all that we need
  693.     prompt()
  694.     {
  695.        echo "$* \\c"
  696.     }
  697.     printf()
  698.     {
  699.        echo "$*\\c"
  700.     }
  701. elif [ "`echo -n foo`@" = "foo@" ]; then
  702.     # BSD-style echo; use echo -n to get
  703.     # a line without the trailing newline
  704.     prompt()
  705.     {
  706.        echo -n "$* "
  707.     }
  708. else
  709.     # something else; do without
  710.     prompt()
  711.     {
  712.     echo "$*"
  713.     }
  714. fi
  715. t=`printf hello` 2>/dev/null
  716. if [ "$t" != "hello" ]; then
  717.     echo "You don't seem to have a System V-style echo command"
  718.     echo "or a BSD-style printf command.  I'm bailing out..."
  719.     exit 1
  720. fi
  721.  
  722. #
  723. # If the killall program is not present on the system
  724. # cobble together a shell function to emulate the
  725. # functionality that we need.
  726. #
  727. (killall -l >/dev/null) 2>/dev/null || {
  728.     killall()
  729.     {
  730.     # NB: ps ax should give an error on System V, so we try it first!
  731.     pid="`ps ax 2>/dev/null | grep $2 | grep -v grep | awk '{print $1;}'`"
  732.     test "$pid" ||
  733.         pid="`ps -e | grep $2 | grep -v grep | awk '{print $2;}'`"
  734.     test "$pid" && kill $1 $pid; return
  735.     }
  736. }
  737.  
  738. while [ -z "$TTY" -o ! -c /dev/$TTY ]; do
  739.     if [ "$TTY" != "" ]; then
  740.     echo "/dev/$TTY is not a terminal device."
  741.     fi
  742.     prompt "Serial port that modem is connected to [$TTY]?"; read TTY
  743. done
  744.  
  745. #
  746. # Try to deduce if the tty devices are named in the SGI
  747. # sense (ttyd<port>, ttym<port>, and ttyf<port>) or the
  748. # way that everyone else seems to do it--tty<port>
  749. #
  750. # (I'm sure that someone will tell me there is another way as well.)
  751. #
  752. case "$OS" in
  753. IRIX)
  754.     PORT=`expr $TTY : 'tty.\(.*\)'`
  755.     for x in f m d; do
  756.     LOCKX="$LOCKX $LOCKDIR/LCK..tty$x${PORT}"
  757.     done
  758.     DEVS="/dev/ttyd${PORT} /dev/ttym${PORT} /dev/ttyf${PORT}"
  759.     #
  760.     # NB: we use ttyd* device names in the following
  761.     # work so that we are not stopped by a need for DCD.
  762.     #
  763.     tdev=/dev/ttyd${PORT}
  764.     ;;
  765. BSDi|BSD/386|386bsd|386BSD)
  766.     PORT=`expr $TTY : 'com\(.*\)'`
  767.     LOCKX="$LOCKDIR/LCK..$TTY"
  768.     DEVS=/dev/$TTY
  769.     tdev=/dev/$TTY
  770.     ;;
  771. SunOS)
  772.     PORT=`expr $TTY : 'tty\(.*\)'`
  773.     LOCKX="$LOCKDIR/LCK..$TTY"
  774.     DEVS=/dev/$TTY
  775.     tdev=/dev/$TTY
  776.     ;;
  777. *)
  778.     echo "Beware, I am guessing the tty naming conventions on your system:"
  779.     PORT=`expr $TTY : 'tty\(.*\)'`    echo "Serial port: $PORT"
  780.     LOCKX="$LOCKDIR/LCK..$TTY"        echo "UUCP lock file: $LOCKX"
  781.     DEVS=/dev/$TTY tdev=/dev/$TTY    echo "TTY device: $DEVS"
  782.     ;;
  783. esac
  784. CONFIG=$CPATH.$TTY
  785.  
  786. #
  787. # Check that device is not currently being used.
  788. #
  789. if [ ! -d $LOCKDIR ]; then
  790.     prompt "Hmm, uucp lock files are not in \"$LOCKDIR\", where are they?"
  791.     read x
  792.     while [ ! -d $x ]; do
  793.     prompt "Nope, \"$x\" is not a directory; try again:"
  794.     read x
  795.     done
  796.     LOCKDIR=$x
  797. fi
  798. for x in $LOCKX; do
  799.     if [ -f $x ]; then
  800.     echo "Sorry, the device is currently in use by another program."
  801.     exit 1
  802.     fi
  803. done
  804.  
  805. #
  806. # Lock the device for later use when deducing the modem type.
  807. #
  808. JUNK="$LOCKX $OUT"
  809. trap "rm -f $JUNK; exit 1" 0 1 2 15
  810.  
  811. LOCKSTR=`expr "         $$" : '.*\(..........\)'`
  812. # lock the device by all of its names
  813. for x in $LOCKX; do
  814.     echo "$LOCKSTR" > $x
  815. done
  816. # zap any gettys or other users
  817. fuser -k $DEVS >/dev/null 2>&1 || {
  818.     cat<<EOF
  819. Hmm, there does not appear to be an fuser command on your machine.
  820. This means that I am unable to insure that all processes using the
  821. modem have been killed.  I will keep going, but beware that you may
  822. have competition for the modem.
  823. EOF
  824. }
  825.  
  826. cat<<EOF
  827.  
  828. Now we are going to probe the tty port.  This takes a few seconds,
  829. so be patient.  Note that if you do not have the modem cabled to
  830. the port, or the modem is turned off, this may hang (just go and
  831. cable up the modem or turn it on, or whatever).
  832. EOF
  833.  
  834. if [ $OS = "SunOS" ]; then
  835.     #
  836.     # Sun systems have a command for manipulating software
  837.     # carrier on a terminal line.  Set or reset carrier
  838.     # according to the type of tty device being used.
  839.     #
  840.     case $TTY in
  841.     tty*) ttysoftcar -y $TTY;;
  842.     cua*) ttysoftcar -n $TTY;;
  843.     esac
  844. fi
  845.  
  846. #
  847. # Pick the way to invoke stty: if the -f flag is
  848. # available use it so that if CLOCAL is turned off
  849. # on the tty the open by the shell won't hang.
  850. #
  851. if stty -f >/dev/null 2>&1; then
  852.     Stty()
  853.     {
  854.     stty -f $tdev $*
  855.     }
  856. else
  857.     Stty()
  858.     {
  859.     stty $* <$tdev
  860.     }
  861. fi
  862.  
  863. #
  864. # Send each command in SendString to the modem and collect
  865. # the result in $OUT.  Read this very carefully.  It's got
  866. # a lot of magic in it!
  867. #
  868. SendToModem()
  869. {
  870.     Stty 0                    # reset the modem (hopefully)
  871.     catpid=`$CAT <$tdev >$OUT& echo $!`        # start listening for output
  872.     Stty $SPEED -echo -icrnl -ixon -ixoff -isig clocal; sleep 1
  873.     printf "\rATQ0V1E1\r" >$tdev; sleep 1;    # enable echo and result codes
  874.     for i in $*; do
  875.     printf "$i\r" >$tdev; sleep 1;
  876.     done
  877.     kill -9 $catpid; catpid=
  878.     pat=`echo "$i"|sed -e 's/[+*&$\\]/\\\\&/g'`    # escape regex metacharacters
  879.     RESPONSE=`tr -d '\015' < $OUT | \
  880.     sed -n "/$pat/{n;s/ *$//;p;q;}" | sed -e 's/AT\+F.*=//' -e 's/\+F.*=//'`
  881. }
  882.  
  883. RESULT="";
  884. while [ -z "$RESULT" ]; do
  885.     #
  886.     # This goes in the background while we try to
  887.     # reset the modem.  If something goes wrong, it'll
  888.     # nag the user to check on the problem.
  889.     #
  890.     (trap 0 1 2 15;
  891.      while true; do
  892.     sleep 5;
  893.     echo ""
  894.     echo "Hmm, something seems to be hung, check your modem eh?"
  895.      done)& nagpid=$!
  896.     trap "rm -f $JUNK; kill $nagpid \$catpid; exit 1" 0 1 2 15
  897.  
  898.     SendToModem "AT+FCLASS=?"             # ask for class support
  899.  
  900.     kill $nagpid
  901.     trap "rm -f $JUNK; test "$catpid" && kill $catpid; exit 1" 0 1 2 15
  902.     sleep 1
  903.  
  904.     RESULT=`tr -d "\015" < $OUT | tail -1`
  905.     if [ -z "$RESPONSE" ]; then
  906.     echo ""
  907.     echo "There was no response from the modem.  Perhaps the modem is"
  908.     echo "turned off or the cable between the modem and host is not"
  909.     echo "connected.  Please check the modem and hit a carriage return"
  910.     prompt "when you are ready to try again:"
  911.     read x
  912.     fi
  913. done
  914.  
  915. Try()
  916. {
  917.     catpid=`$CAT <$tdev >$OUT& echo $!`        # start listening for output
  918.     Stty $SPEED -echo -icrnl -ixon -ixoff -isig clocal; sleep 1
  919.     for i in $*; do
  920.     printf "$i\r" >$tdev; sleep 1;
  921.     done
  922.     kill -9 $catpid; catpid=
  923.     pat=`echo "$i"|sed -e 's/[+*&$\\]/\\\\&/g'`    # escape regex metacharacters
  924.     RESPONSE=`tr -d '\015' < $OUT | sed -n "/$pat/{n;s/ *$//;p;q;}"`
  925.     RESULT=`tr -d "\015" < $OUT | tail -1`
  926.  
  927.     printf "$*    RESULT = \"$RESULT\"    RESPONSE = \"$RESPONSE\"\n"
  928. }
  929.  
  930. TryClass2Commands()
  931. {
  932.     Try "AT+FCLASS=?";    Try "AT+FCLASS?"
  933.     Try "AT+FCLASS=0";    Try "AT+FCLASS=1";    Try "AT+FCLASS=2"
  934.     Try "AT+FCLASS?"
  935.     Try "AT+FJUNK=?";    Try "AT+FJUNK?"
  936.     Try "AT+FAA=?";    Try "AT+FAA?"
  937.     Try "AT+FAXERR=?";    Try "AT+FAXERR?"
  938.     Try "AT+FBADLIN=?";    Try "AT+FBADLIN?"
  939.     Try "AT+FBADMUL=?";    Try "AT+FBADMUL?"
  940.     Try "AT+FBOR=?";    Try "AT+FBOR?"
  941.     Try "AT+FBUF=?";    Try "AT+FBUF?"
  942.     Try "AT+FBUG=?";    Try "AT+FBUG?"
  943.     Try "AT+FCIG=?";    Try "AT+FCIG?"
  944.     Try "AT+FCQ=?";    Try "AT+FCQ?"
  945.     Try "AT+FCR=?";    Try "AT+FCR?"
  946.     Try "AT+FTBC=?";    Try "AT+FTBC?"
  947.     Try "AT+FDCC=?";    Try "AT+FDCC?"
  948.     Try "AT+FDCS=?";    Try "AT+FDCS?"
  949.     Try "AT+FDIS=?";    Try "AT+FDIS?"
  950.     Try "AT+FDT=?";    Try "AT+FDT?"
  951.     Try "AT+FECM=?";    Try "AT+FECM?"
  952.     Try "AT+FET=?";    Try "AT+FET?"
  953.     Try "AT+FLID=?";    Try "AT+FLID?"
  954.     Try "AT+FLNFC=?";    Try "AT+FLNFC?"
  955.     Try "AT+FLPL=?";    Try "AT+FLPL?"
  956.     Try "AT+FMDL?";    Try "AT+FMFR?"
  957.     Try "AT+FMINSP=?";    Try "AT+FMINSP?"
  958.     Try "AT+FPHCTO=?";    Try "AT+FPHCTO?"
  959.     Try "AT+FPTS=?";    Try "AT+FPTS?"
  960.     Try "AT+FRBC=?";    Try "AT+FRBC?"
  961.     Try "AT+FREL=?";    Try "AT+FREL?"
  962.     Try "AT+FREV?";
  963.     Try "AT+FSPL=?";    Try "AT+FSPL?"
  964.     Try "AT+FTBC=?";    Try "AT+FTBC?"
  965.     Try "AT+FVRFC=?";    Try "AT+FVRFC?"
  966.     Try "AT+FWDFC=?";    Try "AT+FWDFC?"
  967. }
  968.  
  969. TryClass1Commands()
  970. {
  971.     Try "AT+FCLASS=?";    Try "AT+FCLASS?"
  972.     Try "AT+FCLASS=0";    Try "AT+FCLASS=1"
  973.     Try "AT+FCLASS?"
  974.     Try "AT+FJUNK=?";    Try "AT+FJUNK?"
  975.     Try "AT+FAA=?";    Try "AT+FAA?"
  976.     Try "AT+FAE=?";    Try "AT+FAE?"
  977.     Try "AT+FTH=?"
  978.     Try "AT+FRH=?"
  979.     Try "AT+FTM=?"
  980.     Try "AT+FRM=?"
  981.     Try "AT+FTS=?"
  982.     Try "AT+FRS=?"
  983. }
  984.  
  985. TryCommonCommands()
  986. {
  987.     for i in 0 1 2 3; do
  988.     Try "ATI$i"
  989.     done
  990. }
  991.  
  992. echo ""
  993. if [ "$RESULT" = "OK" ]; then
  994.     # Looks like a Class 1 or 2 modem, get more information
  995.     case "`echo $RESPONSE | sed -e 's/[()]//g'`" in
  996.     2|0,2|2,*|0,2,*)
  997.     echo "This looks like a Class 2 modem."
  998.     echo ""
  999.     TryCommonCommands
  1000.     echo ""; echo "Class 2 stuff..."; echo ""
  1001.     TryClass2Commands
  1002.     ;;
  1003.     0,1,2|0,1,2,*)
  1004.     echo "This looks like a Class 1+2 modem."
  1005.     echo ""
  1006.     TryCommonCommands
  1007.     echo ""; echo "Class 1 stuff..."; echo ""
  1008.     TryClass1Commands
  1009.     echo ""; echo "Class 2 stuff..."; echo ""
  1010.     TryClass2Commands
  1011.     ;;
  1012.     1|0,1|0,1,*)
  1013.     echo "This looks like a Class 1 modem."
  1014.     echo ""
  1015.     TryCommonCommands
  1016.     echo ""; echo "Class 1 stuff..."; echo ""
  1017.     TryClass1Commands
  1018.     exit
  1019.     ;;
  1020.     *)    echo "The result of the AT+FCLASS=? command was:"
  1021.     echo ""
  1022.     cat $OUT
  1023.     echo ""
  1024.     echo "I don't figure that it's worthwhile to continue..."
  1025.     exit
  1026.     ;;
  1027.     esac
  1028. else
  1029.     echo "This not a Class 1 or Class 2 modem,"
  1030.     exit
  1031. fi
  1032. EOF-EOF-EOF
  1033. Patch faxcover/Makefile<<'EOF-EOF-EOF'
  1034. 2c2
  1035. < #    $Header: /usr/people/sam/fax/faxcover/RCS/Makefile,v 1.15 93/04/18 18:05:12 sam Exp $
  1036. ---
  1037. > #    $Header: /usr/people/sam/fax/faxcover/RCS/Makefile,v 1.16 93/06/18 11:44:33 sam Exp $
  1038. 49c49
  1039. <     ${INSTALL} -F ${LIB} -m 644 \
  1040. ---
  1041. >     ${INSTALL} -F ${LIBDATA} -m 644 \
  1042. EOF-EOF-EOF
  1043. Patch faxcover/faxcover.c++<<'EOF-EOF-EOF'
  1044. 1c1
  1045. < /*    $Header: /usr/people/sam/fax/faxcover/RCS/faxcover.c++,v 1.21 93/05/17 16:59:00 sam Exp $
  1046. ---
  1047. > /*    $Header: /usr/people/sam/fax/faxcover/RCS/faxcover.c++,v 1.23 93/06/23 14:03:43 sam Exp $
  1048. 39a40
  1049. > #include <stdlib.h>
  1050. 99a101,104
  1051. >     const char* cp = getenv("FAXCOVER");
  1052. >     if (cp && *cp)
  1053. >     cover = cp;
  1054. 189c194
  1055. <         fd = ::open((char*) (fxStr(FAX_LIBDIR) | "/" | cover), O_RDONLY);
  1056. ---
  1057. >         fd = ::open((char*) (fxStr(FAX_LIBDATA) | "/" | cover), O_RDONLY);
  1058. EOF-EOF-EOF
  1059. Patch faxd/Class1.h<<'EOF-EOF-EOF'
  1060. 1c1
  1061. < /*    $Header: /usr/people/sam/fax/faxd/RCS/Class1.h,v 1.29 93/05/10 09:26:43 sam Exp $
  1062. ---
  1063. > /*    $Header: /usr/people/sam/fax/faxd/RCS/Class1.h,v 1.31 93/06/22 18:16:18 sam Exp $
  1064. 93c93
  1065. <             u_int f2, u_int dics, fxStr& emsg);
  1066. ---
  1067. >             u_int f2, u_int dics, u_int timer, fxStr& emsg);
  1068. 142c142
  1069. <     fxBool    sendPhaseB(TIFF* tif, Class2Params&, u_int pfm, fxStr& emsg);
  1070. ---
  1071. >     fxBool    sendPhaseB(TIFF* tif, Class2Params&, fxStr& pph, fxStr& emsg);
  1072. EOF-EOF-EOF
  1073. Patch faxd/Class1Poll.c++<<'EOF-EOF-EOF'
  1074. 1c1
  1075. < /*    $Header: /usr/people/sam/fax/faxd/RCS/Class1Poll.c++,v 1.4 93/03/25 15:13:40 sam Exp $
  1076. ---
  1077. > /*    $Header: /usr/people/sam/fax/faxd/RCS/Class1Poll.c++,v 1.5 93/06/22 18:19:17 sam Exp $
  1078. 25a26
  1079. > #include "ModemConfig.h"
  1080. 41c42
  1081. <     return recvIdentification(FCF_CIG, cig, FCF_DTC, dtc, emsg);
  1082. ---
  1083. >     return recvIdentification(FCF_CIG, cig, FCF_DTC, dtc, conf.t1Timer, emsg);
  1084. EOF-EOF-EOF
  1085. Patch faxd/Class1Recv.c++<<'EOF-EOF-EOF'
  1086. 1c1
  1087. < /*    $Header: /usr/people/sam/fax/faxd/RCS/Class1Recv.c++,v 1.34 93/05/10 16:28:23 sam Exp $
  1088. ---
  1089. > /*    $Header: /usr/people/sam/fax/faxd/RCS/Class1Recv.c++,v 1.37 93/06/24 15:18:33 sam Exp $
  1090. 55c55
  1091. <  * Process an answerresponse from the modem.
  1092. ---
  1093. >  * Process an answer response from the modem.
  1094. 59c59,60
  1095. <  * message here to mean "CONNECT FAX".
  1096. ---
  1097. >  * message here to force the high level code to
  1098. >  * probe further.
  1099. 65c66
  1100. <     { "CONNECT", 7,    FaxModem::OK, FaxModem::CALLTYPE_FAX };
  1101. ---
  1102. >     { "CONNECT", 7,    FaxModem::OK, FaxModem::CALLTYPE_UNKNOWN };
  1103. 80c81,82
  1104. <     FCF_CSI|FCF_RCVR, lid, FCF_DIS|FCF_RCVR, modemDIS(), emsg);
  1105. ---
  1106. >     FCF_CSI|FCF_RCVR, lid, FCF_DIS|FCF_RCVR, modemDIS(),
  1107. >     conf.class1RecvIdentTimer, emsg);
  1108. 89c91
  1109. <     fxStr& emsg)
  1110. ---
  1111. >     u_int timer, fxStr& emsg)
  1112. 91c93,94
  1113. <     u_int t1 = howmany(conf.t1Timer, 1000);    // T1 timer in seconds
  1114. ---
  1115. >     u_int t1 = howmany(timer, 1000);        // in seconds
  1116. >     u_int trecovery = howmany(conf.class1TrainingRecovery, 1000);
  1117. 95,103c98,106
  1118. <     emsg = "";
  1119. <     do {
  1120. <     /*
  1121. <      * Transmit (NSF) (CSI) DIS frames when the receiving
  1122. <      * station or (NSC) (CIG) DTC when initiating a poll.
  1123. <      */
  1124. <     startTimeout(3000);
  1125. <     fxBool framesSent = sendFrame(f1, id, FALSE);
  1126. <     stopTimeout("sending id frame");
  1127. ---
  1128. >     emsg = "No answer (T.30 T1 timeout)";
  1129. >     /*
  1130. >      * Transmit (NSF) (CSI) DIS frames when the receiving
  1131. >      * station or (NSC) (CIG) DTC when initiating a poll.
  1132. >      */
  1133. >     startTimeout(3000);
  1134. >     fxBool framesSent = sendFrame(f1, id, FALSE);
  1135. >     stopTimeout("sending id frame");
  1136. >     for (;;) {
  1137. 127c130,131
  1138. <             if (recvTraining())
  1139. ---
  1140. >             if (recvTraining()) {
  1141. >             emsg = "";
  1142. 128a133
  1143. >             }
  1144. 129a135,144
  1145. >             /*
  1146. >              * Reset the timeout to insure the T1 timer is
  1147. >              * used.  This is done because the adaptive answer
  1148. >              * strategy may setup a shorter timeout that's
  1149. >              * used to wait for the initial identification
  1150. >              * frame.  If we get here then we know the remote
  1151. >              * side is a fax machine and so we should wait
  1152. >              * the full T1 timeout, as specified by the protocol.
  1153. >              */
  1154. >             t1 = howmany(conf.t1Timer, 1000);
  1155. 134,139c149,151
  1156. <      * If we failed to send our frames or failed to
  1157. <      * receive DCS from the other side, then delay
  1158. <      * long enough to miss any training that the other
  1159. <      * side might have sent us.  Otherwise the caller
  1160. <      * will miss our retransmission since it'll be
  1161. <      * in the process of sending training.
  1162. ---
  1163. >      * We failed to send our frames or failed to receive
  1164. >      * DCS from the other side.  First verify there is
  1165. >      * time to make another attempt...
  1166. 140a153,160
  1167. >     if (time(0)+trecovery-start >= t1)
  1168. >         break;
  1169. >     /*
  1170. >      * Delay long enough to miss any training that the
  1171. >      * other side might have sent us.  Otherwise the
  1172. >      * caller will miss our retransmission since it'll
  1173. >      * be in the process of sending training.
  1174. >      */
  1175. 142,144c162,166
  1176. <     } while (time(0)-start < t1 && class1Cmd("TH", 3, AT_CONNECT));
  1177. <     if (emsg == "")
  1178. <     emsg = "No answer (T.30 T1 timeout)";
  1179. ---
  1180. >     /*
  1181. >      * Retransmit ident frames.
  1182. >      */
  1183. >         framesSent = transmitFrame(f1, id, FALSE);
  1184. >     }
  1185. EOF-EOF-EOF
  1186. Patch faxd/Class1Send.c++<<'EOF-EOF-EOF'
  1187. 1c1
  1188. < /*    $Header: /usr/people/sam/fax/faxd/RCS/Class1Send.c++,v 1.39 93/05/10 17:48:22 sam Exp $
  1189. ---
  1190. > /*    $Header: /usr/people/sam/fax/faxd/RCS/Class1Send.c++,v 1.41 93/06/23 12:03:39 sam Exp $
  1191. 180,182c180,181
  1192. <  * parameters.  The pfm is the post-file-message
  1193. <  * to use as the post-page-message after sending
  1194. <  * the last page of the file.
  1195. ---
  1196. >  * parameters.  The pph is the post-page-handling
  1197. >  * indicators calculated prior to intiating the call.
  1198. 185c184
  1199. < Class1Modem::sendPhaseB(TIFF* tif, Class2Params& next, u_int pfm, fxStr& emsg)
  1200. ---
  1201. > Class1Modem::sendPhaseB(TIFF* tif, Class2Params& next, fxStr& pph, fxStr& emsg)
  1202. 221c220,230
  1203. <     int cmd = (morePages ? FCF_MPS : modemPFMCodes[pfm&7]);
  1204. ---
  1205. >     int cmd;
  1206. >     // XXX check pph length
  1207. >     switch (pph[0]) {
  1208. >     default:
  1209. >         morePages = FALSE;
  1210. >         emsg = "Unknown post-page-handling indicator \"" | pph | "\"";
  1211. >         /* fall thru... */
  1212. >     case 'P': cmd = FCF_EOP; break;
  1213. >     case 'M': cmd = FCF_EOM; break;
  1214. >     case 'S': cmd = FCF_MPS; break;
  1215. >     }
  1216. 240a250
  1217. >         protoTrace("SEND send %s", ppmNames[cmd&0xf]);
  1218. 256a267
  1219. >         pph.remove(0);        // discard post-page-handling
  1220. EOF-EOF-EOF
  1221. Patch faxd/Class2.h<<'EOF-EOF-EOF'
  1222. 1c1
  1223. < /*    $Header: /usr/people/sam/fax/faxd/RCS/Class2.h,v 1.45 93/04/10 11:38:23 sam Exp $
  1224. ---
  1225. > /*    $Header: /usr/people/sam/fax/faxd/RCS/Class2.h,v 1.46 93/05/25 17:34:14 sam Exp $
  1226. 101c101
  1227. <     fxBool    sendPhaseB(TIFF* tif, Class2Params&, u_int pfm, fxStr& emsg);
  1228. ---
  1229. >     fxBool    sendPhaseB(TIFF* tif, Class2Params&, fxStr& pph, fxStr& emsg);
  1230. EOF-EOF-EOF
  1231. Patch faxd/Class2Params.c++<<'EOF-EOF-EOF'
  1232. 1c1
  1233. < /*    $Header: /usr/people/sam/fax/faxd/RCS/Class2Params.c++,v 1.8 93/03/17 14:11:35 sam Exp $
  1234. ---
  1235. > /*    $Header: /usr/people/sam/fax/faxd/RCS/Class2Params.c++,v 1.9 93/06/22 18:19:51 sam Exp $
  1236. 204a205,214
  1237. > u_int Class2Params::stDCSTab[8] = {
  1238. >     DISMINSCAN_0MS<<1,        // ST_0MS
  1239. >     DISMINSCAN_5MS<<1,        // ST_5MS
  1240. >     DISMINSCAN_10MS<<1,        // ST_10MS2
  1241. >     DISMINSCAN_10MS<<1,        // ST_10MS
  1242. >     DISMINSCAN_20MS<<1,        // ST_20MS2
  1243. >     DISMINSCAN_20MS<<1,        // ST_20MS
  1244. >     DISMINSCAN_40MS<<1,        // ST_40MS2
  1245. >     DISMINSCAN_40MS<<1,        // ST_40MS
  1246. > };
  1247. 333c343
  1248. <         | stDISTab[st&7]
  1249. ---
  1250. >         | stDCSTab[st&7]
  1251. EOF-EOF-EOF
  1252. Patch faxd/Class2Params.h<<'EOF-EOF-EOF'
  1253. 1c1
  1254. < /*    $Header: /usr/people/sam/fax/faxd/RCS/Class2Params.h,v 1.5 93/03/12 11:21:58 sam Exp $
  1255. ---
  1256. > /*    $Header: /usr/people/sam/fax/faxd/RCS/Class2Params.h,v 1.6 93/06/22 18:19:34 sam Exp $
  1257. 48c48,49
  1258. <     static u_int stDISTab[8];        // min scanline time
  1259. ---
  1260. >     static u_int stDISTab[8];        // min scanline time (DIS specific)
  1261. >     static u_int stDCSTab[8];        // min scanline time (DCS specific)
  1262. EOF-EOF-EOF
  1263. Patch faxd/Class2Send.c++<<'EOF-EOF-EOF'
  1264. 1c1
  1265. < /*    $Header: /usr/people/sam/fax/faxd/RCS/Class2Send.c++,v 1.53 93/03/25 15:14:05 sam Exp $
  1266. ---
  1267. > /*    $Header: /usr/people/sam/fax/faxd/RCS/Class2Send.c++,v 1.55 93/06/21 12:46:01 sam Exp $
  1268. 55a56,59
  1269. >     case AT_OTHER:
  1270. >     if (streq(rbuf, "CED", 3))        // hack for busted modems
  1271. >         return (dialResponse());
  1272. >     break;
  1273. 127,129c131,132
  1274. <  * parameters.  The pfm is the post-file-message
  1275. <  * to use as the post-page-message after sending
  1276. <  * the last page of the file.
  1277. ---
  1278. >  * parameters.  The pph is the post-page-handling
  1279. >  * indicators calculated prior to intiating the call.
  1280. 132c135
  1281. < Class2Modem::sendPhaseB(TIFF* tif, Class2Params& next, u_int pfm, fxStr& emsg)
  1282. ---
  1283. > Class2Modem::sendPhaseB(TIFF* tif, Class2Params& next, fxStr& pph, fxStr& emsg)
  1284. 170a174,184
  1285. >         u_int ppm;
  1286. >         // XXX check pph length
  1287. >         switch (pph[0]) {
  1288. >         default:
  1289. >         morePages = FALSE;
  1290. >         emsg = "Unknown post-page-handling indicator \"" | pph | "\"";
  1291. >         /* fall thru... */
  1292. >         case 'P': ppm = PPM_EOP; break;
  1293. >         case 'M': ppm = PPM_EOM; break;
  1294. >         case 'S': ppm = PPM_MPS; break;
  1295. >         }
  1296. 172c186
  1297. <         if (pageDone(morePages ? PPM_MPS : pfm, ppr)) {
  1298. ---
  1299. >         if (pageDone(ppm, ppr)) {
  1300. 177a192
  1301. >             pph.remove(0);    // discard post-page-handling
  1302. EOF-EOF-EOF
  1303. Patch faxd/DialRules.c++<<'EOF-EOF-EOF'
  1304. 1c1
  1305. < /*    $Header: /usr/people/sam/fax/faxd/RCS/DialRules.c++,v 1.7 93/05/16 16:19:26 sam Exp $
  1306. ---
  1307. > /*    $Header: /usr/people/sam/fax/faxd/RCS/DialRules.c++,v 1.8 93/06/20 19:14:05 sam Exp $
  1308. 269c269
  1309. <         v.remove(i);
  1310. ---
  1311. >         v.remove(i), n--;
  1312. EOF-EOF-EOF
  1313. Patch faxd/Everex.h<<'EOF-EOF-EOF'
  1314. 1c1
  1315. < /*    $Header: /usr/people/sam/fax/faxd/RCS/Everex.h,v 1.36 93/05/10 09:26:45 sam Exp $
  1316. ---
  1317. > /*    $Header: /usr/people/sam/fax/faxd/RCS/Everex.h,v 1.37 93/05/25 17:34:16 sam Exp $
  1318. 102c102
  1319. <     fxBool    sendPhaseB(TIFF* tif, Class2Params&, u_int pfm, fxStr& emsg);
  1320. ---
  1321. >     fxBool    sendPhaseB(TIFF* tif, Class2Params&, fxStr& pph, fxStr& emsg);
  1322. EOF-EOF-EOF
  1323. Patch faxd/EverexSend.c++<<'EOF-EOF-EOF'
  1324. 1c1
  1325. < /*    $Header: /usr/people/sam/fax/faxd/RCS/EverexSend.c++,v 1.45 93/03/25 15:14:20 sam Exp $
  1326. ---
  1327. > /*    $Header: /usr/people/sam/fax/faxd/RCS/EverexSend.c++,v 1.46 93/05/25 17:34:17 sam Exp $
  1328. 140,142c140,141
  1329. <  * parameters.  The pfm is the post-file-message
  1330. <  * to use as the post-page-message after sending
  1331. <  * the last page of the file.
  1332. ---
  1333. >  * parameters.  The pph is the post-page-handling
  1334. >  * indicators calculated prior to intiating the call.
  1335. 145c144
  1336. < EverexModem::sendPhaseB(TIFF* tif, Class2Params& next, u_int pfm, fxStr& emsg)
  1337. ---
  1338. > EverexModem::sendPhaseB(TIFF* tif, Class2Params& next, fxStr& pph, fxStr& emsg)
  1339. 177c176,186
  1340. <     int cmd = (morePages ? FCF_MPS : modemPFMCodes[pfm&7]);
  1341. ---
  1342. >     int cmd;
  1343. >     // XXX check pph length
  1344. >     switch (pph[0]) {
  1345. >     default:
  1346. >         morePages = FALSE;
  1347. >         emsg = "Unknown post-page-handling indicator \"" | pph | "\"";
  1348. >         /* fall thru... */
  1349. >     case 'P': cmd = FCF_EOP; break;
  1350. >     case 'M': cmd = FCF_EOM; break;
  1351. >     case 'S': cmd = FCF_MPS; break;
  1352. >     }
  1353. 191a201
  1354. >         pph.remove(0);        // discard post-page-handling
  1355. EOF-EOF-EOF
  1356. Patch faxd/FaxModem.c++<<'EOF-EOF-EOF'
  1357. 1c1
  1358. < /*    $Header: /usr/people/sam/fax/faxd/RCS/FaxModem.c++,v 1.73 93/05/10 16:25:40 sam Exp $
  1359. ---
  1360. > /*    $Header: /usr/people/sam/fax/faxd/RCS/FaxModem.c++,v 1.75 93/06/22 18:21:08 sam Exp $
  1361. 291,293c291,294
  1362. <     if (atype != ANSTYPE_ANY && conf.answerCmd[atype] == "")
  1363. <     atype = ANSTYPE_ANY;
  1364. <     if (atCmd(conf.answerCmd[atype], AT_NOTHING)) {
  1365. ---
  1366. >     AnswerType t = atype;
  1367. >     if (t != ANSTYPE_ANY && conf.answerCmd[t] == "")
  1368. >     t = ANSTYPE_ANY;
  1369. >     if (atCmd(conf.answerCmd[t], AT_NOTHING)) {
  1370. 294a296,309
  1371. >     if (ctype == CALLTYPE_UNKNOWN) {
  1372. >         /*
  1373. >          * The response does not uniquely identify the type
  1374. >          * of call; assume the type corresponds to the type
  1375. >          * of the answer request.
  1376. >          */
  1377. >         static CallType unknownCall[] = {
  1378. >         CALLTYPE_FAX,    // ANSTYPE_ANY (default)
  1379. >         CALLTYPE_DATA,    // ANSTYPE_DATA
  1380. >         CALLTYPE_FAX,    // ANSTYPE_FAX
  1381. >         CALLTYPE_VOICE,    // ANSTYPE_VOICE
  1382. >         };
  1383. >         ctype = unknownCall[atype];
  1384. >     }
  1385. 902c917
  1386. <     if (atCmd(conf.softResetCmd, AT_OK, 3))
  1387. ---
  1388. >     if (atCmd(conf.softResetCmd, AT_OK, conf.resetDelay))
  1389. EOF-EOF-EOF
  1390. Patch faxd/FaxModem.h<<'EOF-EOF-EOF'
  1391. 1c1
  1392. < /*    $Header: /usr/people/sam/fax/faxd/RCS/FaxModem.h,v 1.63 93/05/10 16:24:58 sam Exp $
  1393. ---
  1394. > /*    $Header: /usr/people/sam/fax/faxd/RCS/FaxModem.h,v 1.65 93/06/22 18:20:27 sam Exp $
  1395. 82a83
  1396. >     CALLTYPE_UNKNOWN = 4,    // unknown variety
  1397. 313c314
  1398. <      * The post file message parameter to sendPhaseB enables the
  1399. ---
  1400. >      * The post page handling parameter to sendPhaseB enables the
  1401. 323c324
  1402. <     virtual fxBool sendPhaseB(TIFF*, Class2Params&, u_int pfm, fxStr& emsg) = 0;
  1403. ---
  1404. >     virtual fxBool sendPhaseB(TIFF*, Class2Params&, fxStr& pph, fxStr& emsg) = 0;
  1405. EOF-EOF-EOF
  1406. Patch faxd/FaxRecv.c++<<'EOF-EOF-EOF'
  1407. 1c1
  1408. < /*    $Header: /usr/people/sam/fax/faxd/RCS/FaxRecv.c++,v 1.52 93/04/19 08:32:03 sam Exp $
  1409. ---
  1410. > /*    $Header: /usr/people/sam/fax/faxd/RCS/FaxRecv.c++,v 1.53 93/06/22 18:21:46 sam Exp $
  1411. 45c45
  1412. < void
  1413. ---
  1414. > fxBool
  1415. 54a55,56
  1416. >     fxBool faxRecognized = FALSE;
  1417. 63c65
  1418. <     if (modem->recvBegin(emsg)) {
  1419. ---
  1420. >     if (faxRecognized = modem->recvBegin(emsg)) {
  1421. 67c69
  1422. <     } else
  1423. ---
  1424. >     } else {
  1425. 68a71,72
  1426. >         TIFFClose(tif);
  1427. >     }
  1428. 70d73
  1429. <     modem->hangup();
  1430. 87a91
  1431. >     return (faxRecognized);
  1432. EOF-EOF-EOF
  1433. Patch faxd/FaxRecvInfo.c++<<'EOF-EOF-EOF'
  1434. 1c1
  1435. < /*    $Header: /usr/people/sam/fax/faxd/RCS/FaxRecvInfo.c++,v 1.1 93/03/26 10:14:29 sam Exp $
  1436. ---
  1437. > /*    $Header: /usr/people/sam/fax/faxd/RCS/FaxRecvInfo.c++,v 1.2 93/05/25 17:31:33 sam Exp $
  1438. 30c30
  1439. < fxIMPLEMENT_Array(FaxRecvInfoArray, FaxRecvInfo);
  1440. ---
  1441. > fxIMPLEMENT_ObjArray(FaxRecvInfoArray, FaxRecvInfo);
  1442. EOF-EOF-EOF
  1443. Patch faxd/FaxRecvInfo.h<<'EOF-EOF-EOF'
  1444. 1c1
  1445. < /*    $Header: /usr/people/sam/fax/faxd/RCS/FaxRecvInfo.h,v 1.9 93/03/26 10:15:40 sam Exp $
  1446. ---
  1447. > /*    $Header: /usr/people/sam/fax/faxd/RCS/FaxRecvInfo.h,v 1.10 93/05/25 17:31:15 sam Exp $
  1448. 35c35,36
  1449. < struct FaxRecvInfo {
  1450. ---
  1451. > class FaxRecvInfo : public fxObj {
  1452. > public:
  1453. 50c51
  1454. < fxDECLARE_Array(FaxRecvInfoArray, FaxRecvInfo);
  1455. ---
  1456. > fxDECLARE_ObjArray(FaxRecvInfoArray, FaxRecvInfo);
  1457. EOF-EOF-EOF
  1458. RmFile faxd/FaxRecvdData.c++
  1459. Patch faxd/FaxRequest.c++<<'EOF-EOF-EOF'
  1460. 1c1
  1461. < /*    $Header: /usr/people/sam/fax/faxd/RCS/FaxRequest.c++,v 1.30 93/05/03 12:10:29 sam Exp $
  1462. ---
  1463. > /*    $Header: /usr/people/sam/fax/faxd/RCS/FaxRequest.c++,v 1.31 93/05/25 17:34:19 sam Exp $
  1464. 143a144,145
  1465. >     } else if (isCmd("pagehandling")) {// page analysis info
  1466. >         pagehandling = tag;
  1467. 218a221
  1468. >     fprintf(fp, "pagehandling:%s\n", (char*) pagehandling);
  1469. EOF-EOF-EOF
  1470. Patch faxd/FaxRequest.h<<'EOF-EOF-EOF'
  1471. 1c1
  1472. < /*    $Header: /usr/people/sam/fax/faxd/RCS/FaxRequest.h,v 1.24 93/05/03 12:10:33 sam Exp $
  1473. ---
  1474. > /*    $Header: /usr/people/sam/fax/faxd/RCS/FaxRequest.h,v 1.25 93/05/25 17:34:20 sam Exp $
  1475. 88a89
  1476. >     fxStr    pagehandling;    // page analysis information
  1477. EOF-EOF-EOF
  1478. RmFile faxd/FaxRequestData.c++
  1479. Patch faxd/FaxSend.c++<<'EOF-EOF-EOF'
  1480. 1c1
  1481. < /*    $Header: /usr/people/sam/fax/faxd/RCS/FaxSend.c++,v 1.73 93/05/04 13:19:03 sam Exp $
  1482. ---
  1483. > /*    $Header: /usr/people/sam/fax/faxd/RCS/FaxSend.c++,v 1.74 93/05/25 17:34:21 sam Exp $
  1484. 58,60c58,64
  1485. <          * Construct the phone number to dial by crafting the
  1486. <          * canonical form (+<country><areacode><number>), and
  1487. <          * preparing the form to use in dialing the telephone.
  1488. ---
  1489. >          * Prepare the job for transmission by analysing
  1490. >          * the page characteristics and determining whether
  1491. >          * or not the page transfer parameters will have
  1492. >          * to be renegotiated after the page is sent.  This
  1493. >          * is done before the call is placed because it can
  1494. >          * be slow and there can be timing problems if this
  1495. >          * is done during transmission.
  1496. 62,68c66,81
  1497. <         fxStr canon = canonicalizePhoneNumber(fax.number);
  1498. <         fxStr dial = prepareDialString(fax.number);
  1499. <         log = new FaxMachineLog(canon);
  1500. <         setServerStatus("Sending job %s to %s",
  1501. <         (char*) fax.jobid, (char*) canon);
  1502. <         sendFax(fax, dial, canon);
  1503. <         delete log, log = NULL;
  1504. ---
  1505. >         fxStr emsg;
  1506. >         if (sendPrepareFax(fax, emsg)) {
  1507. >         /*
  1508. >          * Construct the phone number to dial by crafting the
  1509. >          * canonical form (+<country><areacode><number>), and
  1510. >          * preparing the form to use in dialing the telephone.
  1511. >          */
  1512. >         fxStr canon = canonicalizePhoneNumber(fax.number);
  1513. >         fxStr dial = prepareDialString(fax.number);
  1514. >         log = new FaxMachineLog(canon);
  1515. >         setServerStatus("Sending job %s to %s",
  1516. >             (char*) fax.jobid, (char*) canon);
  1517. >         sendFax(fax, dial, canon);
  1518. >         delete log, log = NULL;
  1519. >         } else
  1520. >         sendFailed(fax, send_failed, emsg);
  1521. 174,178c187
  1522. <         // NB: all files are coalesced into a single fax document
  1523. <         u_int pfm = (i < fax.ops.length()-1 &&
  1524. <             fax.ops.find(op, i+1) != fx_invalidArrayIndex) ?
  1525. <             PPM_MPS : PPM_EOP;
  1526. <         if (!sendFaxPhaseB(fax, fax.files[i], pfm))
  1527. ---
  1528. >         if (!sendFaxPhaseB(fax, fax.files[i]))
  1529. 300c309
  1530. < FaxServer::sendFaxPhaseB(FaxRequest& fax, const fxStr& file, u_int pfm)
  1531. ---
  1532. > FaxServer::sendFaxPhaseB(FaxRequest& fax, const fxStr& file)
  1533. 316c325,326
  1534. <         status = modem->sendPhaseB(tif, clientParams, pfm, fax.notice);
  1535. ---
  1536. >         status = modem->sendPhaseB(tif, clientParams,
  1537. >         fax.pagehandling, fax.notice);
  1538. 410a421,497
  1539. >  * Prepare the job for transmission by analysing
  1540. >  * the page characteristics and determining whether
  1541. >  * or not the page transfer parameters will have
  1542. >  * to be renegotiated after the page is sent.  This
  1543. >  * is done before the call is placed because it can
  1544. >  * be slow and there can be timing problems if this
  1545. >  * is done during transmission.
  1546. >  */
  1547. > fxBool
  1548. > FaxServer::sendPrepareFax(FaxRequest& fax, fxStr& emsg)
  1549. > {
  1550. >     if (fax.pagehandling != "")        // already done
  1551. >     return (TRUE);
  1552. >     /*
  1553. >      * Scan the pages and figure out where session parameters
  1554. >      * will need to be renegotiated.  Construct a string of
  1555. >      * indicators to use when doing the actual transmission.
  1556. >      *
  1557. >      * NB: all files are coalesced into a single fax document
  1558. >      *     if possible
  1559. >      */
  1560. >     Class2Params params;        // current parameters
  1561. >     Class2Params next;            // parameters for next page
  1562. >     TIFF* tif = NULL;            // current open TIFF image
  1563. >     params.df = (u_int) -1;        // indicates first page
  1564. >     for (u_int i = 0;;) {
  1565. >     if (!tif || TIFFLastDirectory(tif)) {
  1566. >         /*
  1567. >          * Locate the next file to be sent.
  1568. >          */
  1569. >         if (tif)            // close previous file
  1570. >         TIFFClose(tif), tif = NULL;
  1571. >         if (i >= fax.ops.length())
  1572. >         goto done;
  1573. >         FaxSendOp op = send_tiff;
  1574. >         i = fax.ops.find(op, i);
  1575. >         if (i == fx_invalidArrayIndex)
  1576. >         goto done;
  1577. >         tif = TIFFOpen(fax.files[i], "r");
  1578. >         if (tif == NULL) {
  1579. >         emsg = "Can not open document file";
  1580. >         goto bad;
  1581. >         }
  1582. >         i++;            // advance for next find
  1583. >     } else {
  1584. >         /*
  1585. >          * Read the next TIFF directory.
  1586. >          */
  1587. >         if (!TIFFReadDirectory(tif)) {
  1588. >         emsg = "Problem reading document directory";
  1589. >         goto bad;
  1590. >         }
  1591. >     }
  1592. >     next = params;
  1593. >     if (!sendSetupParams1(tif, next, emsg))
  1594. >         goto bad;
  1595. >     if (params.df != (u_int) -1) {
  1596. >         /*
  1597. >          * The pagehandling string has:
  1598. >          * 'M' = EOM, for when parameters must be renegotiated
  1599. >          * 'S' = MPS, for when next page uses the same parameters
  1600. >          * 'P' = EOP, for the last page to be transmitted
  1601. >          */
  1602. >         fax.pagehandling.append(next == params ? 'S' : 'M');
  1603. >     }
  1604. >     params = next;
  1605. >     }
  1606. > done:
  1607. >     fax.pagehandling.append('P');        // EOP
  1608. >     return (TRUE);
  1609. > bad:
  1610. >     if (tif)
  1611. >     TIFFClose(tif);
  1612. >     return (FALSE);
  1613. > }
  1614. > /*
  1615. 424c511
  1616. < FaxServer::sendSetupParams(TIFF* tif, Class2Params& params, fxStr& emsg)
  1617. ---
  1618. > FaxServer::sendSetupParams1(TIFF* tif, Class2Params& params, fxStr& emsg)
  1619. 519,527d605
  1620. <     traceStatus(FAXTRACE_PROTOCOL, "USE %s",
  1621. <     Class2Params::pageWidthNames[params.wd]);
  1622. <     traceStatus(FAXTRACE_PROTOCOL, "USE %s",
  1623. <     Class2Params::pageLengthNames[params.ln]);
  1624. <     traceStatus(FAXTRACE_PROTOCOL, "USE %s",
  1625. <     Class2Params::vresNames[params.vr]);
  1626. <     traceStatus(FAXTRACE_PROTOCOL, "USE %s",
  1627. <     Class2Params::dataFormatNames[params.df]);
  1628. 528a607,623
  1629. > }
  1630. > fxBool
  1631. > FaxServer::sendSetupParams(TIFF* tif, Class2Params& params, fxStr& emsg)
  1632. > {
  1633. >     if (sendSetupParams1(tif, params, emsg)) {
  1634. >     traceStatus(FAXTRACE_PROTOCOL, "USE %s",
  1635. >         Class2Params::pageWidthNames[params.wd]);
  1636. >     traceStatus(FAXTRACE_PROTOCOL, "USE %s",
  1637. >         Class2Params::pageLengthNames[params.ln]);
  1638. >     traceStatus(FAXTRACE_PROTOCOL, "USE %s",
  1639. >         Class2Params::vresNames[params.vr]);
  1640. >     traceStatus(FAXTRACE_PROTOCOL, "USE %s",
  1641. >         Class2Params::dataFormatNames[params.df]);
  1642. >     return (TRUE);
  1643. >     } else
  1644. >     return (FALSE);
  1645. EOF-EOF-EOF
  1646. Patch faxd/FaxServer.c++<<'EOF-EOF-EOF'
  1647. 1c1
  1648. < /*    $Header: /usr/people/sam/fax/faxd/RCS/FaxServer.c++,v 1.115 93/05/20 11:02:05 sam Exp $
  1649. ---
  1650. > /*    $Header: /usr/people/sam/fax/faxd/RCS/FaxServer.c++,v 1.116 93/06/23 12:07:20 sam Exp $
  1651. 115a116,118
  1652. >     adaptiveAnswer = FALSE;        // don't answer data if fax answer fails
  1653. >     answerBias = -1;
  1654. >     setAnswerRotary("any");
  1655. 621c624
  1656. < FaxServer::answerPhone(AnswerType type, fxBool force)
  1657. ---
  1658. > FaxServer::answerPhone(AnswerType atype, fxBool force)
  1659. 628,654c631,653
  1660. <         switch (modem->answerCall(type, emsg)) {
  1661. <         case FaxModem::CALLTYPE_FAX:
  1662. <         traceStatus(FAXTRACE_SERVER, "ANSWER: FAX CONNECTION");
  1663. <         recvFax();
  1664. <         break;
  1665. <         case FaxModem::CALLTYPE_DATA:
  1666. <         traceStatus(FAXTRACE_SERVER, "ANSWER: DATA CONNECTION");
  1667. <         // fork getty to handle data connection
  1668. <         if (gettyArgs != "") {
  1669. <             if (modem->dataService()) {
  1670. <             if (runGetty(gettyArgs)) {
  1671. <                 delete log, log = NULL;
  1672. <                 return;    // NB: don't unlock until getty exits
  1673. <             }
  1674. <             } else
  1675. <             traceStatus(FAXTRACE_SERVER,
  1676. <                 "ANSWER: Could not switch modem to data service");
  1677. <         } else
  1678. <             traceStatus(FAXTRACE_SERVER,
  1679. <             "ANSWER: Data connections are not permitted");
  1680. <         break;
  1681. <         case FaxModem::CALLTYPE_VOICE:
  1682. <         traceStatus(FAXTRACE_SERVER, "ANSWER: VOICE CONNECTION");
  1683. <         break;
  1684. <         case FaxModem::CALLTYPE_ERROR:
  1685. <         traceStatus(FAXTRACE_SERVER, "ANSWER: %s", (char*) emsg);
  1686. <         break;
  1687. ---
  1688. >         /*
  1689. >          * If requested, rotate the way we answer the phone
  1690. >          * if the request type is "any".  This should probably
  1691. >          * only be used if the modem does not directly support
  1692. >          * adaptive-answer.
  1693. >          */
  1694. >         if (atype == FaxModem::ANSTYPE_ANY)
  1695. >         atype = answerRotary[answerRotor];
  1696. >         CallType ctype = modem->answerCall(atype, emsg);
  1697. >         fxBool waitForProcess;
  1698. >         fxBool callSetup = setupCall(atype, ctype, waitForProcess, emsg);
  1699. >         if (!callSetup && ctype == FaxModem::CALLTYPE_FAX && adaptiveAnswer) {
  1700. >         /*
  1701. >          * Status indicated a call from a fax machine, but we
  1702. >          * were unable to complete the initial handshake.
  1703. >          * If we are doing adaptive answer, immediately
  1704. >          * retry answering the call as data w/o hanging up
  1705. >          * the phone (note that this depends on characteristics
  1706. >          * of the local phone system).
  1707. >          */
  1708. >         atype = FaxModem::ANSTYPE_DATA;
  1709. >         ctype = modem->answerCall(atype, emsg);
  1710. >         callSetup = setupCall(atype, ctype, waitForProcess, emsg);
  1711. 655a655,676
  1712. >         /*
  1713. >          * Call resolved.  If we were able to recognize the call
  1714. >          * type and setup a session, then reset the answer rotary
  1715. >          * state if there is a bias toward a specific answer type.
  1716. >          * Also, deal with call types that are processed through
  1717. >          * a subprocess, rather than within this process.  Otherwise,
  1718. >          * if the call failed, advance the rotor to the next answer
  1719. >          * type in preparation for the next call.
  1720. >          */
  1721. >         if (callSetup) {
  1722. >         if (answerBias >= 0)
  1723. >             answerRotor = answerBias;
  1724. >         /*
  1725. >          * Some calls are handled by starting up a subprocess
  1726. >          * that does the work.  For such calls we have to wait
  1727. >          * for the process to exit before we can remove the
  1728. >          * lock file and do related cleanup work.
  1729. >          */
  1730. >         if (waitForProcess)
  1731. >             return;
  1732. >         } else
  1733. >         answerRotor = (answerRotor+1) % answerRotorSize;
  1734. 689a711,776
  1735. >  * Do setup after answering an incoming call.
  1736. >  */
  1737. > fxBool
  1738. > FaxServer::setupCall(AnswerType atype, CallType ctype, fxBool& waitForProcess,
  1739. >     fxStr& emsg)
  1740. > {
  1741. >     fxBool callSetup = FALSE;
  1742. >     waitForProcess = FALSE;
  1743. >     switch (ctype) {
  1744. >     case FaxModem::CALLTYPE_FAX:
  1745. >     traceStatus(FAXTRACE_SERVER, "ANSWER: FAX CONNECTION");
  1746. >     callSetup = recvFax();
  1747. >     break;
  1748. >     case FaxModem::CALLTYPE_DATA:
  1749. >     traceStatus(FAXTRACE_SERVER, "ANSWER: DATA CONNECTION");
  1750. >     if (gettyArgs == "") {
  1751. >         traceStatus(FAXTRACE_SERVER,
  1752. >         "ANSWER: Data connections are not permitted");
  1753. >         break;
  1754. >     }
  1755. >     /*
  1756. >      * If call was answered using an adaptive-answering
  1757. >      * facility, then give the modem an opportunity to
  1758. >      * establish data services.
  1759. >      */
  1760. >     if (atype == FaxModem::ANSTYPE_ANY && !modem->dataService()) {
  1761. >         traceStatus(FAXTRACE_SERVER,
  1762. >         "ANSWER: Could not switch modem to data service");
  1763. >         break;
  1764. >     }
  1765. >     /*
  1766. >      * Fork and exec a getty process to handle the
  1767. >      * data connection.  Note that we return without
  1768. >      * removing our lock on the modem--this is done
  1769. >      * after we reap the child getty process to insure
  1770. >      * outgoing modem use is disallowed.
  1771. >      */
  1772. >     if (runGetty(gettyArgs)) {
  1773. >         delete log, log = NULL;
  1774. >         callSetup = TRUE;
  1775. >         waitForProcess = TRUE;
  1776. >     }
  1777. >     break;
  1778. >     case FaxModem::CALLTYPE_VOICE:
  1779. >     traceStatus(FAXTRACE_SERVER, "ANSWER: VOICE CONNECTION");
  1780. >     /*
  1781. >      * If call was answered using an adaptive-answering
  1782. >      * facility, then give the modem an opportunity to
  1783. >      * establish voice services.
  1784. >      */
  1785. >     if (atype == FaxModem::ANSTYPE_ANY && !modem->voiceService()) {
  1786. >         traceStatus(FAXTRACE_SERVER,
  1787. >         "ANSWER: Could not switch modem to voice service");
  1788. >         break;
  1789. >     }
  1790. >     // XXX setup voice process a la getty
  1791. >     break;
  1792. >     case FaxModem::CALLTYPE_ERROR:
  1793. >     traceStatus(FAXTRACE_SERVER, "ANSWER: %s", (char*) emsg);
  1794. >     break;
  1795. >     }
  1796. >     return (callSetup);
  1797. > }
  1798. > /*
  1799. 876a964,972
  1800. > static fxBool
  1801. > getbool(const char* cp)
  1802. > {
  1803. >     return (streq(cp, "on") || streq(cp, "yes"));
  1804. > }
  1805. > /*
  1806. >  * Process an answer rotary spec string.
  1807. >  */
  1808. 877a974,999
  1809. > FaxServer::setAnswerRotary(const fxStr& value)
  1810. > {
  1811. >     u_int l = 0;
  1812. >     for (u_int i = 0; i < 3 && l < value.length(); i++) {
  1813. >     fxStr type(value.token(l, " \t"));
  1814. >     type.raisecase();
  1815. >     if (type == "FAX")
  1816. >         answerRotary[i] = FaxModem::ANSTYPE_FAX;
  1817. >     else if (type == "DATA")
  1818. >         answerRotary[i] = FaxModem::ANSTYPE_DATA;
  1819. >     else if (type == "VOICE")
  1820. >         answerRotary[i] = FaxModem::ANSTYPE_VOICE;
  1821. >     else {
  1822. >         if (type != "ANY")
  1823. >         traceStatus(FAXTRACE_SERVER,
  1824. >             "Unknown answer type \"%s\"", (char*) type);
  1825. >         answerRotary[i] = FaxModem::ANSTYPE_ANY;
  1826. >     }
  1827. >     }
  1828. >     if (i == 0)                // void string
  1829. >     answerRotary[i++] = FaxModem::ANSTYPE_ANY;
  1830. >     answerRotor = 0;
  1831. >     answerRotorSize = i;
  1832. > }
  1833. > void
  1834. 953a1076,1079
  1835. >     else if (streq(tag, "adaptiveanswer"))    adaptiveAnswer = getbool(value);
  1836. >     else if (streq(tag, "answerrotary"))    setAnswerRotary(value);
  1837. >     else if (streq(tag, "answerbias"))
  1838. >     answerBias = fxmin(getnum(value),2);
  1839. EOF-EOF-EOF
  1840. Patch faxd/FaxServer.h<<'EOF-EOF-EOF'
  1841. 1c1
  1842. < /*    $Header: /usr/people/sam/fax/faxd/RCS/FaxServer.h,v 1.80 93/05/10 09:26:48 sam Exp $
  1843. ---
  1844. > /*    $Header: /usr/people/sam/fax/faxd/RCS/FaxServer.h,v 1.82 93/06/23 12:04:20 sam Exp $
  1845. 53c53
  1846. < const long TIMER_POLLGETTY    = 60;    // poll getty done once a minute
  1847. ---
  1848. > const long TIMER_POLLGETTY    = 30;    // poll getty done twice a minute
  1849. 96a97,101
  1850. >     fxBool    adaptiveAnswer;        // answer as data if fax answer fails
  1851. >     short    answerBias;        // rotor bias applied after good calls
  1852. >     u_short    answerRotor;        // rotor into possible selections
  1853. >     u_short    answerRotorSize;    // rotor table size
  1854. >     AnswerType    answerRotary[3];    // rotary selection of answer types
  1855. 132a138
  1856. >     fxBool    sendPrepareFax(FaxRequest& fax, fxStr& emsg);
  1857. 134c140
  1858. <     fxBool    sendFaxPhaseB(FaxRequest& fax, const fxStr& file, u_int pfm);
  1859. ---
  1860. >     fxBool    sendFaxPhaseB(FaxRequest& fax, const fxStr& file);
  1861. 136a143
  1862. >     fxBool    sendSetupParams1(TIFF*, Class2Params&, fxStr& emsg);
  1863. 140c147
  1864. <     void    recvFax();
  1865. ---
  1866. >     fxBool    recvFax();
  1867. 149c156,158
  1868. < // data connection support
  1869. ---
  1870. > // miscellaneous stuff
  1871. >     fxBool    setupCall(AnswerType atype, CallType ctype,
  1872. >             fxBool& waitForProcess, fxStr& emsg);
  1873. 150a160
  1874. >     void    setAnswerRotary(const fxStr& value);
  1875. EOF-EOF-EOF
  1876. Patch faxd/ModemConfig.c++<<'EOF-EOF-EOF'
  1877. 1c1
  1878. < /*    $Header: /usr/people/sam/fax/faxd/RCS/ModemConfig.c++,v 1.17 93/05/10 16:27:22 sam Exp $
  1879. ---
  1880. > /*    $Header: /usr/people/sam/fax/faxd/RCS/ModemConfig.c++,v 1.18 93/06/22 18:20:16 sam Exp $
  1881. 96a97
  1882. >     class1RecvIdentTimer = t1Timer;    // default to standard protocol
  1883. 152d152
  1884. 230a231,232
  1885. >     else if (streq(tag, "Class1RecvIdentTimer"))
  1886. >     class1RecvIdentTimer = atoi(value);
  1887. EOF-EOF-EOF
  1888. Patch faxd/ModemConfig.h<<'EOF-EOF-EOF'
  1889. 1c1
  1890. < /*    $Header: /usr/people/sam/fax/faxd/RCS/ModemConfig.h,v 1.15 93/05/10 16:26:49 sam Exp $
  1891. ---
  1892. > /*    $Header: /usr/people/sam/fax/faxd/RCS/ModemConfig.h,v 1.16 93/06/22 18:19:57 sam Exp $
  1893. 69a70
  1894. >     u_int    class1RecvIdentTimer;    // timeout receiving initial identity
  1895. EOF-EOF-EOF
  1896. Patch faxd/TODO<<'EOF-EOF-EOF'
  1897. 1d0
  1898. < B must do +FET=1 before changing session parameters in Class 2 driver
  1899. EOF-EOF-EOF
  1900. Patch libtiff/Makefile.aix<<'EOF-EOF-EOF'
  1901. 1c1
  1902. < #    $Header: /usr/people/sam/fax/libtiff/RCS/Makefile.aix,v 1.21 93/04/18 18:05:18 sam Exp $
  1903. ---
  1904. > #    $Header: /usr/people/sam/tiff/libtiff/RCS/Makefile.aix,v 1.21 93/04/18 18:05:18 sam Exp $
  1905. EOF-EOF-EOF
  1906. Patch libtiff/Makefile.apollo<<'EOF-EOF-EOF'
  1907. 1c1
  1908. < #    $Header: /usr/people/sam/fax/libtiff/RCS/Makefile.apollo,v 1.35 93/04/18 18:05:18 sam Exp $
  1909. ---
  1910. > #    $Header: /usr/people/sam/tiff/libtiff/RCS/Makefile.apollo,v 1.35 93/04/18 18:05:18 sam Exp $
  1911. EOF-EOF-EOF
  1912. Patch libtiff/Makefile.gcc<<'EOF-EOF-EOF'
  1913. 1c1
  1914. < #    $Header: /usr/people/sam/fax/libtiff/RCS/Makefile.gcc,v 1.4 93/04/18 18:05:19 sam Exp $
  1915. ---
  1916. > #    $Header: /usr/people/sam/tiff/libtiff/RCS/Makefile.gcc,v 1.4 93/04/18 18:05:19 sam Exp $
  1917. EOF-EOF-EOF
  1918. Patch libtiff/Makefile.hpux<<'EOF-EOF-EOF'
  1919. 1c1
  1920. < #    $Header: /usr/people/sam/fax/libtiff/RCS/Makefile.hpux,v 1.34 93/04/18 18:05:20 sam Exp $
  1921. ---
  1922. > #    $Header: /usr/people/sam/tiff/libtiff/RCS/Makefile.hpux,v 1.34 93/04/18 18:05:20 sam Exp $
  1923. EOF-EOF-EOF
  1924. Patch libtiff/Makefile.mips<<'EOF-EOF-EOF'
  1925. 1c1
  1926. < #    $Header: /usr/people/sam/fax/libtiff/RCS/Makefile.mips,v 1.33 93/04/18 18:05:20 sam Exp $
  1927. ---
  1928. > #    $Header: /usr/people/sam/tiff/libtiff/RCS/Makefile.mips,v 1.33 93/04/18 18:05:20 sam Exp $
  1929. EOF-EOF-EOF
  1930. Patch libtiff/Makefile.mpw<<'EOF-EOF-EOF'
  1931. 1c1
  1932. < #    $Header: /usr/people/sam/fax/libtiff/RCS/Makefile.mpw,v 1.3 93/04/18 18:05:21 sam Exp $
  1933. ---
  1934. > #    $Header: /usr/people/sam/tiff/libtiff/RCS/Makefile.mpw,v 1.3 93/04/18 18:05:21 sam Exp $
  1935. EOF-EOF-EOF
  1936. Patch libtiff/Makefile.next<<'EOF-EOF-EOF'
  1937. 1c1
  1938. < #    $Header: /usr/people/sam/fax/libtiff/RCS/Makefile.next,v 1.34 93/04/18 18:05:22 sam Exp $
  1939. ---
  1940. > #    $Header: /usr/people/sam/tiff/libtiff/RCS/Makefile.next,v 1.34 93/04/18 18:05:22 sam Exp $
  1941. EOF-EOF-EOF
  1942. Patch libtiff/Makefile.sco<<'EOF-EOF-EOF'
  1943. 1c1
  1944. < #    $Header: /usr/people/sam/fax/libtiff/RCS/Makefile.sco,v 1.4 93/04/18 18:05:22 sam Exp $
  1945. ---
  1946. > #    $Header: /usr/people/sam/tiff/libtiff/RCS/Makefile.sco,v 1.4 93/04/18 18:05:22 sam Exp $
  1947. EOF-EOF-EOF
  1948. Patch libtiff/Makefile.sgi<<'EOF-EOF-EOF'
  1949. 1c1
  1950. < #    $Header: /usr/people/sam/fax/libtiff/RCS/Makefile.sgi,v 1.54 93/04/18 18:05:23 sam Exp $
  1951. ---
  1952. > #    $Header: /usr/people/sam/tiff/libtiff/RCS/Makefile.sgi,v 1.54 93/04/18 18:05:23 sam Exp $
  1953. EOF-EOF-EOF
  1954. Patch libtiff/Makefile.sun<<'EOF-EOF-EOF'
  1955. 1c1
  1956. < #    $Header: /usr/people/sam/fax/libtiff/RCS/Makefile.sun,v 1.45 93/04/18 18:05:24 sam Exp $
  1957. ---
  1958. > #    $Header: /usr/people/sam/tiff/libtiff/RCS/Makefile.sun,v 1.45 93/04/18 18:05:24 sam Exp $
  1959. EOF-EOF-EOF
  1960. Patch libtiff/Makefile.tahoe<<'EOF-EOF-EOF'
  1961. 1c1
  1962. < #    $Header: /usr/people/sam/fax/libtiff/RCS/Makefile.tahoe,v 1.36 93/04/18 18:05:24 sam Exp $
  1963. ---
  1964. > #    $Header: /usr/people/sam/tiff/libtiff/RCS/Makefile.tahoe,v 1.36 93/04/18 18:05:24 sam Exp $
  1965. EOF-EOF-EOF
  1966. Patch libtiff/Makefile.vax<<'EOF-EOF-EOF'
  1967. 1c1
  1968. < #    $Header: /usr/people/sam/fax/libtiff/RCS/Makefile.vax,v 1.46 93/04/18 18:05:25 sam Exp $
  1969. ---
  1970. > #    $Header: /usr/people/sam/tiff/libtiff/RCS/Makefile.vax,v 1.46 93/04/18 18:05:25 sam Exp $
  1971. EOF-EOF-EOF
  1972. Patch libtiff/README<<'EOF-EOF-EOF'
  1973. 1c1
  1974. < $Header: /usr/people/sam/tiff/libtiff/RCS/README,v 1.16 92/10/21 16:37:31 sam Exp $
  1975. ---
  1976. > $Header: /usr/people/sam/tiff/libtiff/RCS/README,v 1.16 92/10/21 16:37:31 sam Rel $
  1977. EOF-EOF-EOF
  1978. Patch libtiff/mkg3states.c<<'EOF-EOF-EOF'
  1979. 2c2
  1980. < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/mkg3states.c,v 1.15 93/02/14 10:15:25 sam Exp $";
  1981. ---
  1982. > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/mkg3states.c,v 1.15 93/02/14 10:15:25 sam Rel $";
  1983. 46c46
  1984. <  *    Reference: $Id: mkg3states.c,v 1.15 93/02/14 10:15:25 sam Exp $
  1985. ---
  1986. >  *    Reference: $Id: mkg3states.c,v 1.15 93/02/14 10:15:25 sam Rel $
  1987. EOF-EOF-EOF
  1988. Patch libtiff/mkspans.c<<'EOF-EOF-EOF'
  1989. 2c2
  1990. < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/mkspans.c,v 1.6 92/10/21 14:16:20 sam Exp $";
  1991. ---
  1992. > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/mkspans.c,v 1.6 92/10/21 14:16:20 sam Rel $";
  1993. EOF-EOF-EOF
  1994. Patch libtiff/t4.h<<'EOF-EOF-EOF'
  1995. 1c1
  1996. < /* $Header: /usr/people/sam/tiff/libtiff/RCS/t4.h,v 1.9 92/02/10 19:06:22 sam Exp $ */
  1997. ---
  1998. > /* $Header: /usr/people/sam/tiff/libtiff/RCS/t4.h,v 1.9 92/02/10 19:06:22 sam Rel $ */
  1999. EOF-EOF-EOF
  2000. Patch libtiff/tif_apple.c<<'EOF-EOF-EOF'
  2001. 2c2
  2002. < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_apple.c,v 1.10 92/10/30 11:43:23 sam Exp $";
  2003. ---
  2004. > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_apple.c,v 1.10 92/10/30 11:43:23 sam Rel $";
  2005. EOF-EOF-EOF
  2006. Patch libtiff/tif_aux.c<<'EOF-EOF-EOF'
  2007. 2c2
  2008. < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_aux.c,v 1.17 92/11/27 11:41:30 sam Exp $";
  2009. ---
  2010. > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_aux.c,v 1.17 92/11/27 11:41:30 sam Rel $";
  2011. EOF-EOF-EOF
  2012. Patch libtiff/tif_ccittrle.c<<'EOF-EOF-EOF'
  2013. 2c2
  2014. < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_ccittrle.c,v 1.16 92/10/21 13:42:04 sam Exp $";
  2015. ---
  2016. > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_ccittrle.c,v 1.16 92/10/21 13:42:04 sam Rel $";
  2017. EOF-EOF-EOF
  2018. Patch libtiff/tif_close.c<<'EOF-EOF-EOF'
  2019. 2c2
  2020. < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_close.c,v 1.22 92/10/21 13:42:04 sam Exp $";
  2021. ---
  2022. > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_close.c,v 1.22 92/10/21 13:42:04 sam Rel $";
  2023. EOF-EOF-EOF
  2024. Patch libtiff/tif_compress.c<<'EOF-EOF-EOF'
  2025. 2c2
  2026. < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_compress.c,v 1.32 92/10/23 09:45:12 sam Exp $";
  2027. ---
  2028. > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_compress.c,v 1.32 92/10/23 09:45:12 sam Rel $";
  2029. EOF-EOF-EOF
  2030. Patch libtiff/tif_dirinfo.c<<'EOF-EOF-EOF'
  2031. 2c2
  2032. < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_dirinfo.c,v 1.22 92/11/09 11:10:18 sam Exp $";
  2033. ---
  2034. > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_dirinfo.c,v 1.22 92/11/09 11:10:18 sam Rel $";
  2035. EOF-EOF-EOF
  2036. Patch libtiff/tif_dirwrite.c<<'EOF-EOF-EOF'
  2037. 2c2
  2038. < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_dirwrite.c,v 1.27 93/02/27 09:28:23 sam Exp $";
  2039. ---
  2040. > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_dirwrite.c,v 1.27 93/02/27 09:28:23 sam Rel $";
  2041. EOF-EOF-EOF
  2042. Patch libtiff/tif_dumpmode.c<<'EOF-EOF-EOF'
  2043. 2c2
  2044. < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_dumpmode.c,v 1.29 92/10/26 17:08:41 sam Exp $";
  2045. ---
  2046. > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_dumpmode.c,v 1.29 92/10/26 17:08:41 sam Rel $";
  2047. EOF-EOF-EOF
  2048. Patch libtiff/tif_error.c<<'EOF-EOF-EOF'
  2049. 2c2
  2050. < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_error.c,v 1.15 92/10/21 13:42:09 sam Exp $";
  2051. ---
  2052. > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_error.c,v 1.15 92/10/21 13:42:09 sam Rel $";
  2053. EOF-EOF-EOF
  2054. Patch libtiff/tif_flush.c<<'EOF-EOF-EOF'
  2055. 2c2
  2056. < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_flush.c,v 1.16 92/10/21 13:42:11 sam Exp $";
  2057. ---
  2058. > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_flush.c,v 1.16 92/10/21 13:42:11 sam Rel $";
  2059. EOF-EOF-EOF
  2060. Patch libtiff/tif_jpeg.c<<'EOF-EOF-EOF'
  2061. 2c2
  2062. < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_jpeg.c,v 1.6 92/10/21 13:42:12 sam Exp $";
  2063. ---
  2064. > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_jpeg.c,v 1.6 92/10/21 13:42:12 sam Rel $";
  2065. EOF-EOF-EOF
  2066. Patch libtiff/tif_lzw.c<<'EOF-EOF-EOF'
  2067. 2c2
  2068. < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_lzw.c,v 1.46 93/01/28 16:59:24 sam Exp $";
  2069. ---
  2070. > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_lzw.c,v 1.46 93/01/28 16:59:24 sam Rel $";
  2071. EOF-EOF-EOF
  2072. Patch libtiff/tif_machdep.c<<'EOF-EOF-EOF'
  2073. 2c2
  2074. < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_machdep.c,v 1.4 92/10/21 13:42:14 sam Exp $";
  2075. ---
  2076. > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_machdep.c,v 1.4 92/10/21 13:42:14 sam Rel $";
  2077. EOF-EOF-EOF
  2078. Patch libtiff/tif_msdos.c<<'EOF-EOF-EOF'
  2079. 2c2
  2080. < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_msdos.c,v 1.5 92/11/09 11:00:23 sam Exp $";
  2081. ---
  2082. > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_msdos.c,v 1.5 92/11/09 11:00:23 sam Rel $";
  2083. EOF-EOF-EOF
  2084. Patch libtiff/tif_next.c<<'EOF-EOF-EOF'
  2085. 2c2
  2086. < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_next.c,v 1.18 92/10/21 16:36:23 sam Exp $";
  2087. ---
  2088. > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_next.c,v 1.18 92/10/21 16:36:23 sam Rel $";
  2089. EOF-EOF-EOF
  2090. Patch libtiff/tif_open.c<<'EOF-EOF-EOF'
  2091. 2c2
  2092. < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_open.c,v 1.39 92/10/21 14:16:48 sam Exp $";
  2093. ---
  2094. > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_open.c,v 1.39 92/10/21 14:16:48 sam Rel $";
  2095. EOF-EOF-EOF
  2096. Patch libtiff/tif_packbits.c<<'EOF-EOF-EOF'
  2097. 2c2
  2098. < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_packbits.c,v 1.29 92/10/26 17:08:54 sam Exp $";
  2099. ---
  2100. > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_packbits.c,v 1.29 92/10/26 17:08:54 sam Rel $";
  2101. EOF-EOF-EOF
  2102. Patch libtiff/tif_print.c<<'EOF-EOF-EOF'
  2103. 2c2
  2104. < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_print.c,v 1.46 92/10/21 13:42:17 sam Exp $";
  2105. ---
  2106. > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_print.c,v 1.46 92/10/21 13:42:17 sam Rel $";
  2107. EOF-EOF-EOF
  2108. Patch libtiff/tif_strip.c<<'EOF-EOF-EOF'
  2109. 2c2
  2110. < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_strip.c,v 1.9 92/10/21 13:42:18 sam Exp $";
  2111. ---
  2112. > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_strip.c,v 1.9 92/10/21 13:42:18 sam Rel $";
  2113. EOF-EOF-EOF
  2114. Patch libtiff/tif_swab.c<<'EOF-EOF-EOF'
  2115. 2c2
  2116. < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_swab.c,v 1.16 92/10/23 11:13:11 sam Exp $";
  2117. ---
  2118. > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_swab.c,v 1.16 92/10/23 11:13:11 sam Rel $";
  2119. EOF-EOF-EOF
  2120. Patch libtiff/tif_thunder.c<<'EOF-EOF-EOF'
  2121. 2c2
  2122. < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_thunder.c,v 1.21 92/10/21 13:42:20 sam Exp $";
  2123. ---
  2124. > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_thunder.c,v 1.21 92/10/21 13:42:20 sam Rel $";
  2125. EOF-EOF-EOF
  2126. Patch libtiff/tif_tile.c<<'EOF-EOF-EOF'
  2127. 2c2
  2128. < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_tile.c,v 1.12 92/10/21 13:42:20 sam Exp $";
  2129. ---
  2130. > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_tile.c,v 1.12 92/10/21 13:42:20 sam Rel $";
  2131. EOF-EOF-EOF
  2132. Patch libtiff/tif_unix.c<<'EOF-EOF-EOF'
  2133. 2c2
  2134. < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_unix.c,v 1.4 92/10/21 13:42:21 sam Exp $";
  2135. ---
  2136. > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_unix.c,v 1.4 92/10/21 13:42:21 sam Rel $";
  2137. EOF-EOF-EOF
  2138. Patch libtiff/tif_vms.c<<'EOF-EOF-EOF'
  2139. 2c2
  2140. < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_vms.c,v 1.6 92/10/21 13:42:22 sam Exp $";
  2141. ---
  2142. > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_vms.c,v 1.6 92/10/21 13:42:22 sam Rel $";
  2143. EOF-EOF-EOF
  2144. Patch libtiff/tif_warning.c<<'EOF-EOF-EOF'
  2145. 2c2
  2146. < static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_warning.c,v 1.15 92/10/21 13:42:23 sam Exp $";
  2147. ---
  2148. > static char rcsid[] = "$Header: /usr/people/sam/tiff/libtiff/RCS/tif_warning.c,v 1.15 92/10/21 13:42:23 sam Rel $";
  2149. EOF-EOF-EOF
  2150. Patch libtiff/tiff.h<<'EOF-EOF-EOF'
  2151. 1c1
  2152. < /* $Header: /usr/people/sam/tiff/libtiff/RCS/tiff.h,v 1.37 92/08/04 12:27:17 sam Exp $ */
  2153. ---
  2154. > /* $Header: /usr/people/sam/tiff/libtiff/RCS/tiff.h,v 1.37 92/08/04 12:27:17 sam Rel $ */
  2155. EOF-EOF-EOF
  2156. Patch libtiff/tiffcomp.h<<'EOF-EOF-EOF'
  2157. 1c1
  2158. < /* $Header: /usr/people/sam/tiff/libtiff/RCS/tiffcomp.h,v 1.32 92/10/30 11:43:31 sam Exp $ */
  2159. ---
  2160. > /* $Header: /usr/people/sam/tiff/libtiff/RCS/tiffcomp.h,v 1.32 92/10/30 11:43:31 sam Rel $ */
  2161. EOF-EOF-EOF
  2162. Patch libtiff/tiffconf.h<<'EOF-EOF-EOF'
  2163. 1c1
  2164. < /* $Header: /usr/people/sam/tiff/libtiff/RCS/tiffconf.h,v 1.2 92/11/09 11:10:08 sam Exp $ */
  2165. ---
  2166. > /* $Header: /usr/people/sam/tiff/libtiff/RCS/tiffconf.h,v 1.2 92/11/09 11:10:08 sam Rel $ */
  2167. EOF-EOF-EOF
  2168. Patch man/Makefile<<'EOF-EOF-EOF'
  2169. 2c2
  2170. < #    $Header: /usr/people/sam/fax/man/RCS/Makefile,v 1.17 93/05/19 11:33:36 sam Exp $
  2171. ---
  2172. > #    $Header: /usr/people/sam/fax/man/RCS/Makefile,v 1.18 93/06/18 11:45:17 sam Exp $
  2173. 54,55c54,55
  2174. <     -e 's;\$${LIBDATA};${LIB};g'\
  2175. <     -e 's;\$${LIBEXEC};${LIB};g'\
  2176. ---
  2177. >     -e 's;\$${LIBDATA};${LIBDATA};g'\
  2178. >     -e 's;\$${LIBEXEC};${LIBEXEC};g'\
  2179. EOF-EOF-EOF
  2180. Patch man/config.4f<<'EOF-EOF-EOF'
  2181. 1c1
  2182. < .\"    $Header: /usr/people/sam/fax/man/RCS/config.4f,v 1.20 93/05/19 11:33:47 sam Exp $
  2183. ---
  2184. > .\"    $Header: /usr/people/sam/fax/man/RCS/config.4f,v 1.21 93/06/25 14:10:49 sam Exp $
  2185. 27c27
  2186. < .TH CONFIG 4F "May 12, 1993"
  2187. ---
  2188. > .TH CONFIG 4F "June 24, 1993"
  2189. 91a92,94
  2190. > AdaptiveAnswer    boolean    \s-1No\s+1    enable adaptive answer of inbound calls
  2191. > AnswerRotary    string    \s-1any\s+1    alternatives for answering calls
  2192. > AnswerBias    integer    -1    bias to apply to successful rotary answer 
  2193. 154a158,159
  2194. > Class1RecvAbortOK    integer    \s-1100\s+1    Class 1: max wait (ms) for ``\s-1OK\s+1'' after recv abort
  2195. > Class1RecvIdentTimer    integer    \s-135000\s+1    Class 1: max wait (ms) for initial ident frame
  2196. 159d163
  2197. < Class1RecvAbortOK    integer    \s-1100\s+1    Class 1: max wait (ms) for ``\s-1OK\s+1'' after recv abort
  2198. 173a178,247
  2199. > .B AdaptiveAnswer
  2200. > Control whether or not an adaptive answering
  2201. > strategy is used whereby an incoming call is
  2202. > first answered as fax using
  2203. > .B ModemAnswerFaxCmd
  2204. > and then, if that fails, as data using
  2205. > .BR ModemAnswerDataCmd .
  2206. > If the adaptive answer strategy is not enabled, then calls
  2207. > are answered using the appropriate
  2208. > .B ModemAnswer*Cmd
  2209. > parameter (normally
  2210. > .B ModemAnswerCmd
  2211. > for unattended operation).
  2212. > Note that the adaptive answer strategy depends on many factors
  2213. > that limit its usefulness.
  2214. > It typically only works with a Class 1 modem because it is
  2215. > important that the sequence of operations related to answering
  2216. > as fax be completed in a short enough time that a subsequent
  2217. > answer for data be done before the caller times out and hangs
  2218. > up the telephone
  2219. > (for this reason the
  2220. > .B Class1RecvIdentTimer
  2221. > should be set to a value that is shorter than the T1 timer.)
  2222. > Also, note that it is necessary to arrange that the phone be
  2223. > placed on-hook between the two answers; this can typically be
  2224. > done by inserting the appropriate command at the start of
  2225. > .BR ModemAnswerDataCmd .
  2226. > .TP
  2227. > .B AnswerRotary
  2228. > The sequence of answering techniques the server should
  2229. > ``rotate through'' when answer incoming calls.
  2230. > Answering techniques are:
  2231. > .sp .5
  2232. > .ta \w'\fBName\fP    'u
  2233. > .nf
  2234. > \fBName    Description\fP
  2235. > fax    answer a fax call
  2236. > data    answer a data call
  2237. > voice    answer a voice call
  2238. > any    answer a call of any/unknown type
  2239. > .sp .5
  2240. > .fi
  2241. > When a call is not answered succesfully, the server
  2242. > advances the rotary to the next specified answering
  2243. > technique.
  2244. > Successful calls do not effect the current answering technique.
  2245. > For example, if
  2246. > .B AnswerRotary
  2247. > is ``fax data'',
  2248. > then the calls will initially be answered as fax until
  2249. > the first call is received that does not appear to be
  2250. > from a fax machine; after that calls will be answered
  2251. > as if they were from a data modem until the next unsuccessful
  2252. > call; after which they will one again be answered as fax. 
  2253. > See also
  2254. > .BR AnswerBias .
  2255. > .TP
  2256. > .B AnswerBias
  2257. > The index into the
  2258. > .B AnswerRotary
  2259. > list that the server should rotate the list to after
  2260. > each successfull incoming phone call.
  2261. > List indices are numbered starting at zero.
  2262. > For example, if
  2263. > .B AnswerRotary
  2264. > is ``fax data'' and
  2265. > .B AnswerBias
  2266. > is 1, then after each successful inbound call, the
  2267. > next call will be answered as data.
  2268. > .TP
  2269. 474c548
  2270. < for Class 1 and Class 2 modems, but only softare flow control
  2271. ---
  2272. > for Class 1 and Class 2 modems, but only software flow control
  2273. 754a829,856
  2274. > .B Class1FrameOverhead
  2275. > The number of extraneous bytes in
  2276. > .SM HDLC
  2277. > frames sent to the host in response to an ``\s-1AT+FRH\s+1'' command.
  2278. > For modems that properly implement the Class 1 interface, this
  2279. > number should be 4 (the default).
  2280. > .TP
  2281. > .B Class1RecvAbortOK
  2282. > The time, in milliseconds, to wait for an ``\s-1OK\s+1'' result code
  2283. > from the modem after aborting an 
  2284. > .SM HDLC
  2285. > frame receive (``\s-1AT+FRH=3\s+1'').
  2286. > If this number is zero, then the modem is assumed to not correctly
  2287. > implement aborting and instead the driver will wait 200ms,
  2288. > flush any input, and then send ``\s-1AT\en\s+1'' and wait
  2289. > 100ms for an ``\s-1OK\s+1'' result.
  2290. > .TP
  2291. > .B Class1RecvIdentTimer
  2292. > The time, in milliseconds, to wait for an initial
  2293. > .SM DCS
  2294. > when receiving a facsimile.
  2295. > .SM CCITT
  2296. > recommendation T.30 specifies this as the value of the T1 timer.
  2297. > However, adaptive answering schemes such as that described
  2298. > above under the
  2299. > .B AdaptiveAnswer
  2300. > parameter require that this timer be shorter.
  2301. > .TP
  2302. 770,779d871
  2303. < .TP
  2304. < .B Class1RecvAbortOK
  2305. < The time, in milliseconds, to wait for an ``\s-1OK\s+1'' result code
  2306. < from the modem after aborting an 
  2307. < .SM HDLC
  2308. < frame receive (``\s-1AT+FRH=3\s+1'').
  2309. < If this number is zero, then the modem is assumed to not correctly
  2310. < implement aborting and instead the driver will wait 200ms,
  2311. < flush any input, and then send ``\s-1AT\en\s+1'' and wait
  2312. < 100ms for an ``\s-1OK\s+1'' result.
  2313. EOF-EOF-EOF
  2314. Patch man/faxcover.1<<'EOF-EOF-EOF'
  2315. 1c1
  2316. < .\"    $Header: /usr/people/sam/fax/man/RCS/faxcover.1,v 1.11 93/05/14 15:55:18 sam Exp $
  2317. ---
  2318. > .\"    $Header: /usr/people/sam/fax/man/RCS/faxcover.1,v 1.12 93/06/25 14:17:30 sam Exp $
  2319. 27c27
  2320. < .TH FAXCOVER 1 "May 12, 1993"
  2321. ---
  2322. > .TH FAXCOVER 1 "June 25, 1993"
  2323. 135c135,137
  2324. < option.
  2325. ---
  2326. > option by specifying a file in the
  2327. > .B FAXCOVER
  2328. > environment variable.
  2329. EOF-EOF-EOF
  2330. Patch port/386bsd/Makefile<<'EOF-EOF-EOF'
  2331. 2c2
  2332. < #    $Header: /usr/people/sam/fax/port/386bsd/RCS/Makefile,v 1.4 93/04/27 14:59:39 sam Exp $
  2333. ---
  2334. > #    $Header: /usr/people/sam/fax/port/386bsd/RCS/Makefile,v 1.6 93/06/24 10:43:19 sam Exp $
  2335. 81,82c81,82
  2336. <     ${INSTALL} -u bin -g bin -m 755 -idb flexfax.sw.client -dir ${BIN}
  2337. <     ${INSTALL} -u bin -g bin -m 755 -idb flexfax.sw.client -dir ${LIB}
  2338. ---
  2339. >     ${INSTALL} -u bin -g bin -m 755 -idb flexfax.sw.client -dir \
  2340. >         ${BIN} ${LIBDATA} ${LIBEXEC}
  2341. 84c84
  2342. <     ${INSTALL} -u bin -g bin -m 755 -idb flexfax.sw.server -dir ${BIN}
  2343. ---
  2344. >     ${INSTALL} -u bin -g bin -m 755 -idb flexfax.sw.server -dir ${USRETC}
  2345. EOF-EOF-EOF
  2346. Patch port/386bsd/defs<<'EOF-EOF-EOF'
  2347. 1c1
  2348. < #    $Header: /usr/people/sam/fax/port/386bsd/RCS/defs,v 1.14 93/05/17 16:11:48 sam Exp $
  2349. ---
  2350. > #    $Header: /usr/people/sam/fax/port/386bsd/RCS/defs,v 1.15 93/06/18 11:46:15 sam Exp $
  2351. 160c160,161
  2352. < # LIB        client-directed application library support
  2353. ---
  2354. > # LIBDATA    client-directed application library data files
  2355. > # LIBEXEC    client-directed application library executables
  2356. 166c167,168
  2357. < LIB=    /usr/local/lib/fax
  2358. ---
  2359. > LIBDATA=/usr/local/lib/fax
  2360. > LIBEXEC=/usr/local/lib/fax
  2361. EOF-EOF-EOF
  2362. Patch port/4.4bsd/Makefile.flexfax<<'EOF-EOF-EOF'
  2363. 2c2
  2364. < #    $Header: /usr/people/sam/fax/port/4.4bsd/RCS/Makefile.flexfax,v 1.1 93/05/11 10:45:09 sam Exp $
  2365. ---
  2366. > #    $Header: /usr/people/sam/fax/port/4.4bsd/RCS/Makefile.flexfax,v 1.3 93/06/24 10:43:34 sam Exp $
  2367. 82,83c82,83
  2368. <     ${INSTALL} -u bin -g bin -m 755 -idb flexfax.sw.client -dir ${BIN}
  2369. <     ${INSTALL} -u bin -g bin -m 755 -idb flexfax.sw.client -dir ${LIB}
  2370. ---
  2371. >     ${INSTALL} -u bin -g bin -m 755 -idb flexfax.sw.client -dir \
  2372. >         ${BIN} ${LIBDATA} ${LIBEXEC}
  2373. 85c85
  2374. <     ${INSTALL} -u bin -g bin -m 755 -idb flexfax.sw.server -dir ${BIN}
  2375. ---
  2376. >     ${INSTALL} -u bin -g bin -m 755 -idb flexfax.sw.server -dir ${USRETC}
  2377. EOF-EOF-EOF
  2378. Patch port/4.4bsd/defs<<'EOF-EOF-EOF'
  2379. 1c1
  2380. < #    $Header: /usr/people/sam/fax/port/4.4bsd/RCS/defs,v 1.2 93/05/17 16:12:29 sam Exp $
  2381. ---
  2382. > #    $Header: /usr/people/sam/fax/port/4.4bsd/RCS/defs,v 1.3 93/06/18 11:46:18 sam Exp $
  2383. 160c160,161
  2384. < # LIB        client-directed application library support
  2385. ---
  2386. > # LIBDATA    client-directed application library data files
  2387. > # LIBEXEC    client-directed application library executables
  2388. 166c167,168
  2389. < LIB=    /usr/local/lib/fax
  2390. ---
  2391. > LIBDATA=/usr/local/lib/fax
  2392. > LIBEXEC=/usr/local/lib/fax
  2393. EOF-EOF-EOF
  2394. Patch port/bsdi/Makefile.flexfax<<'EOF-EOF-EOF'
  2395. 2c2
  2396. < #    $Header: /usr/people/sam/fax/port/bsdi/RCS/Makefile.flexfax,v 1.11 93/04/27 14:58:02 sam Exp $
  2397. ---
  2398. > #    $Header: /usr/people/sam/fax/port/bsdi/RCS/Makefile.flexfax,v 1.13 93/06/24 10:43:35 sam Exp $
  2399. 82,83c82,83
  2400. <     ${INSTALL} -u bin -g bin -m 755 -idb flexfax.sw.client -dir ${BIN}
  2401. <     ${INSTALL} -u bin -g bin -m 755 -idb flexfax.sw.client -dir ${LIB}
  2402. ---
  2403. >     ${INSTALL} -u bin -g bin -m 755 -idb flexfax.sw.client -dir \
  2404. >         ${BIN} ${LIBDATA} ${LIBEXEC}
  2405. 85c85
  2406. <     ${INSTALL} -u bin -g bin -m 755 -idb flexfax.sw.server -dir ${BIN}
  2407. ---
  2408. >     ${INSTALL} -u bin -g bin -m 755 -idb flexfax.sw.server -dir ${USRETC}
  2409. EOF-EOF-EOF
  2410. Patch port/bsdi/defs<<'EOF-EOF-EOF'
  2411. 1c1
  2412. < #    $Header: /usr/people/sam/fax/port/bsdi/RCS/defs,v 1.21 93/05/17 16:12:30 sam Exp $
  2413. ---
  2414. > #    $Header: /usr/people/sam/fax/port/bsdi/RCS/defs,v 1.22 93/06/18 11:46:18 sam Exp $
  2415. 160c160,161
  2416. < # LIB        client-directed application library support
  2417. ---
  2418. > # LIBDATA    client-directed application library data files
  2419. > # LIBEXEC    client-directed application library executables
  2420. 166c167,168
  2421. < LIB=    /usr/local/lib/flexfax
  2422. ---
  2423. > LIBDATA=/usr/local/lib/flexfax
  2424. > LIBEXEC=/usr/local/lib/flexfax
  2425. EOF-EOF-EOF
  2426. Patch port/sco/Makefile.flexfax<<'EOF-EOF-EOF'
  2427. 2c2
  2428. < #    $Header: /usr/people/sam/fax/port/sco/RCS/Makefile.flexfax,v 1.3 93/04/27 14:58:07 sam Exp $
  2429. ---
  2430. > #    $Header: /usr/people/sam/fax/port/sco/RCS/Makefile.flexfax,v 1.5 93/06/24 10:43:36 sam Exp $
  2431. 82,83c82,83
  2432. <     ${INSTALL} -u bin -g sys -m 755 -idb flexfax.sw.client -dir ${BIN}
  2433. <     ${INSTALL} -u bin -g sys -m 755 -idb flexfax.sw.client -dir ${LIB}
  2434. ---
  2435. >     ${INSTALL} -u bin -g sys -m 755 -idb flexfax.sw.client -dir \
  2436. >         ${BIN} ${LIBDATA} ${LIBEXEC}
  2437. 85c85
  2438. <     ${INSTALL} -u bin -g sys -m 755 -idb flexfax.sw.server -dir ${BIN}
  2439. ---
  2440. >     ${INSTALL} -u bin -g sys -m 755 -idb flexfax.sw.server -dir ${USRETC}
  2441. EOF-EOF-EOF
  2442. Patch port/sco/defs<<'EOF-EOF-EOF'
  2443. 1c1
  2444. < #    $Header: /usr/people/sam/fax/port/sco/RCS/defs,v 1.4 93/04/18 18:06:10 sam Exp $
  2445. ---
  2446. > #    $Header: /usr/people/sam/fax/port/sco/RCS/defs,v 1.5 93/06/18 11:46:20 sam Exp $
  2447. 159c159,160
  2448. < # LIB        client-directed application library support
  2449. ---
  2450. > # LIBDATA    client-directed application library data files
  2451. > # LIBEXEC    client-directed application library executables
  2452. 165c166,167
  2453. < LIB=/u/lib/fax
  2454. ---
  2455. > LIBDATA=/u/lib/fax
  2456. > LIBEXEC=/u/lib/fax
  2457. EOF-EOF-EOF
  2458. Patch port/sgi/Makefile<<'EOF-EOF-EOF'
  2459. 2c2
  2460. < #    $Header: /usr/people/sam/fax/port/sgi/RCS/Makefile,v 1.52 93/04/27 14:59:46 sam Exp $
  2461. ---
  2462. > #    $Header: /usr/people/sam/fax/port/sgi/RCS/Makefile,v 1.54 93/06/24 10:43:37 sam Exp $
  2463. 82,83c82,83
  2464. <     ${INSTALL} -u bin -g sys -m 755 -idb flexfax.sw.client -dir ${BIN}
  2465. <     ${INSTALL} -u bin -g sys -m 755 -idb flexfax.sw.client -dir ${LIB}
  2466. ---
  2467. >     ${INSTALL} -u bin -g sys -m 755 -idb flexfax.sw.client -dir \
  2468. >         ${BIN} ${LIBDATA} ${LIBEXEC}
  2469. 85c85
  2470. <     ${INSTALL} -u bin -g sys -m 755 -idb flexfax.sw.server -dir ${BIN}
  2471. ---
  2472. >     ${INSTALL} -u bin -g sys -m 755 -idb flexfax.sw.server -dir ${USRETC}
  2473. EOF-EOF-EOF
  2474. Patch port/sgi/defs.cc<<'EOF-EOF-EOF'
  2475. 1c1
  2476. < #    $Header: /usr/people/sam/fax/port/sgi/RCS/defs.cc,v 1.35 93/05/17 16:12:31 sam Exp $
  2477. ---
  2478. > #    $Header: /usr/people/sam/fax/port/sgi/RCS/defs.cc,v 1.36 93/06/18 11:46:20 sam Exp $
  2479. 161c161,162
  2480. < # LIB        client-directed application library support
  2481. ---
  2482. > # LIBDATA    client-directed application library data files
  2483. > # LIBEXEC    client-directed application library executables
  2484. 167c168,169
  2485. < LIB=    /usr/local/lib/fax
  2486. ---
  2487. > LIBDATA=/usr/local/lib/fax
  2488. > LIBEXEC=/usr/local/lib/fax
  2489. EOF-EOF-EOF
  2490. Patch port/sgi/defs.gcc<<'EOF-EOF-EOF'
  2491. 1c1
  2492. < #    $Header: /usr/people/sam/fax/port/sgi/RCS/defs.gcc,v 1.9 93/05/17 16:12:32 sam Exp $
  2493. ---
  2494. > #    $Header: /usr/people/sam/fax/port/sgi/RCS/defs.gcc,v 1.10 93/06/18 11:46:21 sam Exp $
  2495. 161c161,162
  2496. < # LIB        client-directed application library support
  2497. ---
  2498. > # LIBDATA    client-directed application library data files
  2499. > # LIBEXEC    client-directed application library executables
  2500. 167c168,169
  2501. < LIB    = /usr/local/lib/fax
  2502. ---
  2503. > LIBDATA=/usr/local/lib/fax
  2504. > LIBEXEC=/usr/local/lib/fax
  2505. EOF-EOF-EOF
  2506. Patch port/solaris2/Makefile<<'EOF-EOF-EOF'
  2507. 2c2
  2508. < #    $Header: /usr/people/sam/fax/port/solaris2/RCS/Makefile,v 1.3 93/04/27 14:59:56 sam Exp $
  2509. ---
  2510. > #    $Header: /usr/people/sam/fax/port/solaris2/RCS/Makefile,v 1.5 93/06/24 10:43:38 sam Exp $
  2511. 81,82c81,82
  2512. <     ${INSTALL} -u bin -g sys -m 755 -idb flexfax.sw.client -dir ${BIN}
  2513. <     ${INSTALL} -u bin -g sys -m 755 -idb flexfax.sw.client -dir ${LIB}
  2514. ---
  2515. >     ${INSTALL} -u bin -g sys -m 755 -idb flexfax.sw.client -dir \
  2516. >         ${BIN} ${LIBDATA} ${LIBEXEC}
  2517. 84c84
  2518. <     ${INSTALL} -u bin -g sys -m 755 -idb flexfax.sw.server -dir ${BIN}
  2519. ---
  2520. >     ${INSTALL} -u bin -g sys -m 755 -idb flexfax.sw.server -dir ${USRETC}
  2521. EOF-EOF-EOF
  2522. Patch port/solaris2/defs<<'EOF-EOF-EOF'
  2523. 1c1
  2524. < #    $Header: /usr/people/sam/fax/port/solaris2/RCS/defs,v 1.6 93/04/18 18:06:17 sam Exp $
  2525. ---
  2526. > #    $Header: /usr/people/sam/fax/port/solaris2/RCS/defs,v 1.7 93/06/18 11:46:22 sam Exp $
  2527. 161c161,162
  2528. < # LIB        client-directed application library support
  2529. ---
  2530. > # LIBDATA    client-directed application library data files
  2531. > # LIBEXEC    client-directed application library executables
  2532. 167c168,169
  2533. < LIB=    /opt/fax/lib
  2534. ---
  2535. > LIBDATA=/opt/fax/lib
  2536. > LIBEXEC=/opt/fax/lib
  2537. EOF-EOF-EOF
  2538. Patch port/sun/Makefile<<'EOF-EOF-EOF'
  2539. 2c2
  2540. < #    $Header: /usr/people/sam/fax/port/sun/RCS/Makefile,v 1.26 93/04/27 14:59:57 sam Exp $
  2541. ---
  2542. > #    $Header: /usr/people/sam/fax/port/sun/RCS/Makefile,v 1.28 93/06/24 10:43:38 sam Exp $
  2543. 81,82c81,82
  2544. <     ${INSTALL} -u bin -g bin -m 755 -idb flexfax.sw.client -dir ${BIN}
  2545. <     ${INSTALL} -u bin -g bin -m 755 -idb flexfax.sw.client -dir ${LIB}
  2546. ---
  2547. >     ${INSTALL} -u bin -g bin -m 755 -idb flexfax.sw.client -dir \
  2548. >         ${BIN} ${LIBDATA} ${LIBEXEC}
  2549. 84c84
  2550. <     ${INSTALL} -u bin -g bin -m 755 -idb flexfax.sw.server -dir ${BIN}
  2551. ---
  2552. >     ${INSTALL} -u bin -g bin -m 755 -idb flexfax.sw.server -dir ${USRETC}
  2553. EOF-EOF-EOF
  2554. Patch port/sun/defs<<'EOF-EOF-EOF'
  2555. 1c1
  2556. < #    $Header: /usr/people/sam/fax/port/sun/RCS/defs,v 1.27 93/05/17 16:12:33 sam Exp $
  2557. ---
  2558. > #    $Header: /usr/people/sam/fax/port/sun/RCS/defs,v 1.28 93/06/18 11:46:23 sam Exp $
  2559. 153c153,154
  2560. < # LIB        client-directed application library support
  2561. ---
  2562. > # LIBDATA    client-directed application library data files
  2563. > # LIBEXEC    client-directed application library executables
  2564. 159c160,161
  2565. < LIB=    /usr/local/lib/fax
  2566. ---
  2567. > LIBDATA=/usr/local/lib/fax
  2568. > LIBEXEC=/usr/local/lib/fax
  2569. EOF-EOF-EOF
  2570. Patch port/svr4/Makefile<<'EOF-EOF-EOF'
  2571. 2c2
  2572. < #    $Header: /usr/people/sam/fax/port/svr4/RCS/Makefile,v 1.5 93/04/27 14:59:57 sam Exp $
  2573. ---
  2574. > #    $Header: /usr/people/sam/fax/port/svr4/RCS/Makefile,v 1.7 93/06/24 10:43:39 sam Exp $
  2575. 81,82c81,82
  2576. <     ${INSTALL} -u bin -g sys -m 755 -idb flexfax.sw.client -dir ${BIN}
  2577. <     ${INSTALL} -u bin -g sys -m 755 -idb flexfax.sw.client -dir ${LIB}
  2578. ---
  2579. >     ${INSTALL} -u bin -g sys -m 755 -idb flexfax.sw.client -dir \
  2580. >         ${BIN} ${LIBDATA} ${LIBEXEC}
  2581. 84c84
  2582. <     ${INSTALL} -u bin -g sys -m 755 -idb flexfax.sw.server -dir ${BIN}
  2583. ---
  2584. >     ${INSTALL} -u bin -g sys -m 755 -idb flexfax.sw.server -dir ${USRETC}
  2585. EOF-EOF-EOF
  2586. Patch port/svr4/defs<<'EOF-EOF-EOF'
  2587. 1c1
  2588. < #    $Header: /usr/people/sam/fax/port/svr4/RCS/defs,v 1.11 93/04/18 18:06:21 sam Exp $
  2589. ---
  2590. > #    $Header: /usr/people/sam/fax/port/svr4/RCS/defs,v 1.12 93/06/18 11:46:24 sam Exp $
  2591. 160c160,161
  2592. < # LIB        client-directed application library support
  2593. ---
  2594. > # LIBDATA    client-directed application library data files
  2595. > # LIBEXEC    client-directed application library executables
  2596. 166c167,168
  2597. < LIB=    /usr/local/lib/fax
  2598. ---
  2599. > LIBDATA=/usr/local/lib/fax
  2600. > LIBEXEC=/usr/local/lib/fax
  2601. EOF-EOF-EOF
  2602. Patch sendfax/sendfax.c++<<'EOF-EOF-EOF'
  2603. 1c1
  2604. < /*    $Header: /usr/people/sam/fax/sendfax/RCS/sendfax.c++,v 1.51 93/05/20 10:41:08 sam Exp $
  2605. ---
  2606. > /*    $Header: /usr/people/sam/fax/sendfax/RCS/sendfax.c++,v 1.52 93/05/21 11:32:49 sam Exp $
  2607. 98d97
  2608. <     setPageSize("default");
  2609. EOF-EOF-EOF
  2610. Patch sgi2fax/Makefile<<'EOF-EOF-EOF'
  2611. 2c2
  2612. < #    $Header: /usr/people/sam/fax/sgi2fax/RCS/Makefile,v 1.16 93/05/06 12:02:37 sam Exp $
  2613. ---
  2614. > #    $Header: /usr/people/sam/fax/sgi2fax/RCS/Makefile,v 1.17 93/06/18 11:45:08 sam Exp $
  2615. 56c56
  2616. <     ${INSTALL} -F ${LIB} -m 755 -idb ${PRODUCT}.sw.client -O sgi2fax
  2617. ---
  2618. >     ${INSTALL} -F ${LIBEXEC} -m 755 -idb ${PRODUCT}.sw.client -O sgi2fax
  2619. EOF-EOF-EOF
  2620. Patch util/Makefile<<'EOF-EOF-EOF'
  2621. 2c2
  2622. < #    $Header: /usr/people/sam/fax/util/RCS/Makefile,v 1.50 93/05/19 15:50:33 sam Exp $
  2623. ---
  2624. > #    $Header: /usr/people/sam/fax/util/RCS/Makefile,v 1.51 93/06/18 11:44:16 sam Exp $
  2625. 89,90c89,90
  2626. <     ${INSTALL} -F ${LIB} -m 755 -idb ${PRODUCT}.sw.client -O textfmt
  2627. <     ${INSTALL} -F ${LIB} -m 444 -idb ${PRODUCT}.sw.client -O \
  2628. ---
  2629. >     ${INSTALL} -F ${LIBEXEC} -m 755 -idb ${PRODUCT}.sw.client -O textfmt
  2630. >     ${INSTALL} -F ${LIBDATA} -m 444 -idb ${PRODUCT}.sw.client -O \
  2631. EOF-EOF-EOF
  2632. Patch util/PageSize.c++<<'EOF-EOF-EOF'
  2633. 1c1
  2634. < /*    $Header: /usr/people/sam/fax/util/RCS/PageSize.c++,v 1.6 93/05/17 17:03:31 sam Exp $
  2635. ---
  2636. > /*    $Header: /usr/people/sam/fax/util/RCS/PageSize.c++,v 1.7 93/06/18 11:44:18 sam Exp $
  2637. 79c79
  2638. <     sprintf(file, "%s/%s", FAX_LIBDIR, FAX_PAGESIZES);
  2639. ---
  2640. >     sprintf(file, "%s/%s", FAX_LIBDATA, FAX_PAGESIZES);
  2641. EOF-EOF-EOF
  2642. Patch util/SendFaxClient.c++<<'EOF-EOF-EOF'
  2643. 1c1
  2644. < /*    $Header: /usr/people/sam/fax/util/RCS/SendFaxClient.c++,v 1.5 93/05/20 10:40:48 sam Exp $
  2645. ---
  2646. > /*    $Header: /usr/people/sam/fax/util/RCS/SendFaxClient.c++,v 1.8 93/06/18 11:44:20 sam Exp $
  2647. 71c71,72
  2648. <     verbose = FALSE;
  2649. ---
  2650. >     typeRules = NULL;
  2651. >     files = new FileInfoArray;
  2652. 73d73
  2653. <     killtime = "now + 1 day";    // default time to kill the job
  2654. 74a75,78
  2655. >     gotPermission = FALSE;
  2656. >     permission = FALSE;
  2657. >     verbose = FALSE;
  2658. >     killtime = "now + 1 day";    // default time to kill the job
  2659. 77c81,82
  2660. <     notify = no_notice;        // default is no email notification
  2661. ---
  2662. >     pageWidth = 0;
  2663. >     pageLength = 0;
  2664. 79d83
  2665. <     typeRules = NULL;
  2666. 81c85
  2667. <     files = new FileInfoArray;
  2668. ---
  2669. >     notify = no_notice;        // default is no email notification
  2670. 98c102,104
  2671. <     typeRules = TypeRules::read(fxStr(FAX_LIBDIR) | "/" | TypeRulesFile);
  2672. ---
  2673. >     if (pageSize == "" && !setPageSize("default"))
  2674. >     return (FALSE);
  2675. >     typeRules = TypeRules::read(fxStr(FAX_LIBDATA) | "/" | TypeRulesFile);
  2676. 217c223
  2677. < void
  2678. ---
  2679. > fxBool
  2680. 221,226c227,236
  2681. <     if (!info)
  2682. <     fxFatal("Unknown page size \"%s\"", name);
  2683. <     pageWidth = info->width();
  2684. <     pageLength = info->height();
  2685. <     pageSize = name;
  2686. <     delete info;
  2687. ---
  2688. >     if (info) {
  2689. >     pageWidth = info->width();
  2690. >     pageLength = info->height();
  2691. >     pageSize = name;
  2692. >     delete info;
  2693. >     return (TRUE);
  2694. >     } else {
  2695. >     printError("Unknown page size \"%s\"", name);
  2696. >     return (FALSE);
  2697. >     }
  2698. 298,301c308,315
  2699. <     char hostname[64];
  2700. <     (void) gethostname(hostname, sizeof (hostname));
  2701. <     struct hostent* hp = gethostbyname(hostname);
  2702. <     mailbox = fxStr(user) | "@" | (hp ? hp->h_name : hostname);
  2703. ---
  2704. >     fxStr acct(user);
  2705. >     if (acct.next(0, '@') == acct.length()) {
  2706. >     char hostname[64];
  2707. >     (void) gethostname(hostname, sizeof (hostname));
  2708. >     struct hostent* hp = gethostbyname(hostname);
  2709. >     mailbox = acct | "@" | (hp ? hp->h_name : hostname);
  2710. >     } else
  2711. >     mailbox = acct;
  2712. EOF-EOF-EOF
  2713. Patch util/SendFaxClient.h<<'EOF-EOF-EOF'
  2714. 1c1
  2715. < /*    $Header: /usr/people/sam/fax/util/RCS/SendFaxClient.h,v 1.3 93/05/20 10:40:59 sam Exp $
  2716. ---
  2717. > /*    $Header: /usr/people/sam/fax/util/RCS/SendFaxClient.h,v 1.4 93/05/21 11:36:08 sam Exp $
  2718. 136c136
  2719. <     void setPageSize(const char* name);
  2720. ---
  2721. >     fxBool setPageSize(const char* name);
  2722. EOF-EOF-EOF
  2723. Patch util/TypeRules.c++<<'EOF-EOF-EOF'
  2724. 1c1
  2725. < /*    $Header: /usr/people/sam/fax/util/RCS/TypeRules.c++,v 1.11 93/05/02 19:23:42 sam Exp $
  2726. ---
  2727. > /*    $Header: /usr/people/sam/fax/util/RCS/TypeRules.c++,v 1.12 93/06/18 11:44:20 sam Exp $
  2728. 190c190
  2729. <         case 'F':    fmtd.append(fxStr(FAX_FILTERDIR));      continue;
  2730. ---
  2731. >         case 'F':    fmtd.append(fxStr(FAX_LIBEXEC));      continue;
  2732. EOF-EOF-EOF
  2733. Patch util/config.h<<'EOF-EOF-EOF'
  2734. 1c1
  2735. < /*    $Header: /usr/people/sam/fax/util/RCS/config.h,v 1.36 93/05/17 15:38:12 sam Exp $
  2736. ---
  2737. > /*    $Header: /usr/people/sam/fax/util/RCS/config.h,v 1.37 93/06/18 11:44:21 sam Exp $
  2738. 36,37c36,37
  2739. < #define FAX_FILTERDIR    "/usr/local/lib/fax"    /* place for filters */
  2740. < #define    FAX_LIBDIR    "/usr/local/lib/fax"    /* place for lib stuff */
  2741. ---
  2742. > #define FAX_LIBEXEC    "/usr/local/lib/fax"    /* place for lib executables */
  2743. > #define    FAX_LIBDATA    "/usr/local/lib/fax"    /* place for lib data files */
  2744. EOF-EOF-EOF
  2745. Patch util/ps2fax.gs.sh<<'EOF-EOF-EOF'
  2746. 2c2
  2747. < #    $Header: /usr/people/sam/fax/util/RCS/ps2fax.gs.sh,v 1.7 93/04/18 18:05:55 sam Exp $
  2748. ---
  2749. > #    $Header: /usr/people/sam/fax/util/RCS/ps2fax.gs.sh,v 1.8 93/05/23 12:26:20 sam Exp $
  2750. 60c60,61
  2751. < 1728x280) paper=letter;;
  2752. ---
  2753. > # 279.4mm is actually correct, but many people round up!
  2754. > 1728x280|1728x279) paper=letter;;
  2755. EOF-EOF-EOF
  2756. Patch util/textfmt.c++<<'EOF-EOF-EOF'
  2757. 1c1
  2758. < /*    $Header: /usr/people/sam/fax/util/RCS/textfmt.c++,v 1.14 93/05/19 15:50:54 sam Exp $
  2759. ---
  2760. > /*    $Header: /usr/people/sam/fax/util/RCS/textfmt.c++,v 1.15 93/06/18 11:28:37 sam Exp $
  2761. 118a119
  2762. > int
  2763. 271c272
  2764. <     exit(0);
  2765. ---
  2766. >     return (0);
  2767. EOF-EOF-EOF
  2768.